Ejemplo n.º 1
0
def plotAllanDev(data, comp, sf):
    B = {1: "Bx", 2: "By", 3: "Bz"}
    g = Gnuplot.Gnuplot()
    g("set logscale xy 10")
    g("set style data linespoints")
#    g("set format y '%.0e'")
    if isinstance(comp, int):
        aldat = data[:,comp]
        aldev = allan.allanDev(aldat, sf)
        d = Gnuplot.Data(aldev[:,0], aldev[:,1], title=str(B[comp]))
        g.plot(d)
        return g
    else:
        for i in comp:
            aldat = data[:,i]
            aldev = allan.allanDev(aldat, sf)
            d = Gnuplot.Data(aldev[:,0], aldev[:,1], title=str(B[i]))
            g.replot(d)
        return g
Ejemplo n.º 2
0
def getAllanDev(data, comp, sf):
    aldat = data[:,comp]
    aldev = allan.allanDev(aldat, sf)
    np.savetxt("al.txt",aldev)
    return aldev