aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEugeniy E. Mikhailov <evgmik@gmail.com>2021-06-13 17:27:47 -0400
committerEugeniy E. Mikhailov <evgmik@gmail.com>2021-06-13 17:27:47 -0400
commit7aa8493a33457e77c01d93db8a1af6492065f095 (patch)
tree0ad2f2a4dd05d01667ea025a13c36b0193f5ef33
parent678c891c359716550d054a9d033084fa19693592 (diff)
downloadpyExpControl-7aa8493a33457e77c01d93db8a1af6492065f095.tar.gz
pyExpControl-7aa8493a33457e77c01d93db8a1af6492065f095.zip
added colors for lines
-rw-r--r--eitControl.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/eitControl.py b/eitControl.py
index 1f69944..5922e31 100644
--- a/eitControl.py
+++ b/eitControl.py
@@ -27,6 +27,7 @@ class Experiment:
self.root = root
self.tic = 0
self.channelsNames2grab={'tic', 'x','rfFreq','dac0', 'dac1', 'adc0', 'adc1', 'adc2', 'adc3'}
+ self.channelsColor = { 'adc0': 'y', 'adc1': 'c', 'adc2': 'm', 'adc3': 'b', 'dac0': 'w', 'dac1': 'g'}
#self.channelsNames2plot={'dac0', 'dac1', 'adc0', 'adc1', 'adc2', 'adc3'}
if args.test:
self.channelsNames2plot={'adc0', 'adc1', 'adc2', 'adc3'}
@@ -207,7 +208,10 @@ class Experiment:
continue
y = self.data[name]
if name not in self.channelGraph:
- color = (255,0,0)
+ if name in self.channelsColor:
+ color = self.channelsColor[name]
+ else:
+ color = (255,0,0)
self.channelGraph[name]=self.dataPlot.plot(x,y, pen=None, symbol='o', symbolPen=None, symbolBrush=color, symbolSize=5)
else:
self.channelGraph[name].setData(x,y)