You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
import numpy as np
import flap
import matplotlib.pyplot as plt
t = flap.Coordinate(
name='Time',
mode=flap.CoordinateMode(equidistant=True),
unit = 'Second',# Here the unit is NOT a Unit class object.
shape=(1000),
start=0,
step=1,
dimension_list=[1]
)
ch = flap.Coordinate(
name='Channel number',
mode=flap.CoordinateMode(equidistant=True),
shape=(3),
start = 1,
step=1,
dimension_list=[0])
ch_name = flap.Coordinate(
name='Signal name',
mode=flap.CoordinateMode(equidistant=False),
shape=(3),
values = ['CH-1','CH-2','CH-3'],
dimension_list = [0]
)
dunit = flap.Unit(name='Amplitude',unit='V')
#create a random array as data
data = np.random.randn(3,1000)
#create a flap data object instace
d = flap.DataObject(data_array = data,
data_unit = dunit,# Here the unit IS a Unit class object.
coordinates = [t,ch,ch_name],
data_title = 'Random series',
exp_id = '17062019_01'
)
import numpy as np
import flap
import matplotlib.pyplot as plt
t = flap.Coordinate(
name='Time',
mode=flap.CoordinateMode(equidistant=True),
unit = 'Second',# Here the unit is NOT a Unit class object.
shape=(1000),
start=0,
step=1,
dimension_list=[1]
)
ch = flap.Coordinate(
name='Channel number',
mode=flap.CoordinateMode(equidistant=True),
shape=(3),
start = 1,
step=1,
dimension_list=[0])
ch_name = flap.Coordinate(
name='Signal name',
mode=flap.CoordinateMode(equidistant=False),
shape=(3),
values = ['CH-1','CH-2','CH-3'],
dimension_list = [0]
)
dunit = flap.Unit(name='Amplitude',unit='V')
#create a random array as data
data = np.random.randn(3,1000)
#create a flap data object instace
d = flap.DataObject(data_array = data,
data_unit = dunit,# Here the unit IS a Unit class object.
coordinates = [t,ch,ch_name],
data_title = 'Random series',
exp_id = '17062019_01'
)
interv = flap.Intervals(0,100,step=100,number=1)
d.plot(axes='Time',slicing={'Signal name':'CH-1','Time':interv})
The text was updated successfully, but these errors were encountered: