This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import matplotlib.pyplot as plt | |
import matplotlib.animation as animation | |
import time | |
import sys | |
fig = plt.figure() | |
ax1 = fig.add_subplot(1,1,1) | |
ax1.ticklabel_format(style="plain") | |
fil = sys.argv[1] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np | |
import json | |
import cloudant | |
import datetime as dt | |
import pytz | |
berlin = pytz.timezone("Europe/Berlin") | |
# set up db and define functions | |
#acct = cloudant.Account(uri="http://10.155.59.88:5984") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np | |
def allanVar(data, sf=1): | |
''' | |
calculates allan variance | |
according to eq 8.13a in | |
David W. Allan, John H. Shoaf and Donald Halford: Statistics of Time and Frequency Data Analysis, | |
NBS Monograph 140, pages 151–204, 1974 | |
''' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import json | |
import cloudant | |
import datetime as dt | |
# set up db and define functions | |
#acct = cloudant.Account(uri="http://10.155.59.88:5984") | |
acct = cloudant.Account(uri="http://raid.nedm1:5984") | |
res = acct.login("nedm_user", "") | |
assert res.status_code == 200 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np | |
def allanVar(data, sf=1): | |
''' | |
calculates allan variance | |
according to eq 8.13a in | |
David W. Allan, John H. Shoaf and Donald Halford: Statistics of Time and Frequency Data Analysis, | |
NBS Monograph 140, pages 151–204, 1974 | |
''' | |
leng = len(data) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
fig, ax = plt.subplots() | |
fig.set_size_inches(8,6) | |
fmt = mdates.DateFormatter("%H:%M", tz=berlin) | |
ax.xaxis.set_major_formatter(fmt) | |
ax.plot_date([i.astimezone(berlin) for i in data["Date"]], data["Bz1"], "-", label="y1") | |
fig.autofmt_xdate() | |
#ax.set_xlim([dt.datetime(2015,8,7,17,0,0), dt.datetime(2015,8,7,19,0,0)]) | |
#ax.set_ylim([-30,40]) | |
plt.legend(loc='center right', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np | |
import json | |
import cloudant | |
import datetime as dt | |
import pytz | |
berlin = pytz.timezone("Europe/Berlin") | |
# set up db and define functions | |
#acct = cloudant.Account(uri="http://10.155.59.88:5984") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import ROOT | |
import numpy as np | |
import re | |
import argparse | |
ROOT.gSystem.Load("/home/stefan/Programs/TWaveform/lib/libWaveWaveBase.so") | |
p = argparse.ArgumentParser() | |
p.add_argument('filena') | |
p.add_argument('samplerate', type=float, help="sample rate") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np | |
import matplotlib.pyplot as plt | |
from mpl_toolkits.axes_grid1 import AxesGrid | |
import argparse | |
parser = argparse.ArgumentParser() | |
parser.add_argument("comp", help = "b field component to be plotted, Bx, By, Bz or normB") | |
args = parser.parse_args() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import cloudant | |
import json | |
import codecs | |
# Authentication | |
acct = cloudant.Account(uri="http://raid.nedm1:5984") | |
res = acct.login("username", "password") | |
assert res.status_code == 200 | |
# Grab the correct database |