Rev | Line | |
---|
[723] | 1 | import usans |
---|
| 2 | import math |
---|
| 3 | |
---|
| 4 | class BT5DataGroup: |
---|
| 5 | '''Class containing a group of BT5 data sets to be treated as one data group''' |
---|
| 6 | def __init__(self, dataSetList=None): |
---|
[724] | 7 | |
---|
| 8 | self.isPlotted = False |
---|
[725] | 9 | self.groupName = None |
---|
| 10 | if dataSetList != None: |
---|
| 11 | self.groupName = dataSetList[0].fileName[0:5] |
---|
[723] | 12 | |
---|
| 13 | def addDataSet(self,addList): |
---|
| 14 | '''Add data sets to the group. Takes a list of data set objects''' |
---|
[724] | 15 | for dataSet in addList: |
---|
[723] | 16 | self.dataSetList.append(dataSet) |
---|
| 17 | |
---|
| 18 | def removeDataSet(self,dataSetName): |
---|
| 19 | '''Remove a data set from the group. Takes a data set name''' |
---|
| 20 | |
---|
| 21 | def plotDataGroup(self,axes,plottype=None,yerrorbars=True): |
---|
| 22 | '''Plot the data group. As with BT5DataSet takes matplotlib axes and some options |
---|
| 23 | |
---|
| 24 | Pass options to each data set. |
---|
| 25 | ''' |
---|
| 26 | |
---|
| 27 | def unplotDataGroup(self): |
---|
| 28 | '''Remove the data group from the plot. |
---|
| 29 | |
---|
| 30 | Calls remove_plot from BT5DataSet |
---|
| 31 | ''' |
---|
| 32 | |
---|
| 33 | def calcAlignVals(self,mv): |
---|
| 34 | '''Return the values we record in the logbook for a given motor position |
---|
| 35 | |
---|
| 36 | Determine which data set the motor val belongs to and call function from that class. |
---|
| 37 | |
---|
[725] | 38 | ''' |
---|
Note: See
TracBrowser
for help on using the repository browser.