Skip to content

Commit 9579dd6

Browse files
committed
Update DS_Plot to show number of runs with all NaNs
1 parent e2e8fb7 commit 9579dd6

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

src/utilities/DS_Plot.py

+7
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,7 @@ def generateCurves(self):
6767
curves.append(curve)
6868
count += 1
6969

70+
self.numRunsAllNans = (self.data[i].isna().sum(axis=0) == self.data[i].shape[0]).sum()
7071
if self.data[i].dropna(how='all').empty:
7172
missingData.append(True)
7273
# Label each curve with a unique identifier
@@ -110,4 +111,10 @@ def generateImage(self):
110111
legend = hv.NdOverlay({n: hv.Points([np.nan, np.nan], label=str(n)).opts(color=c) for n, c in color_key})
111112
image = image*legend
112113

114+
# This currently is only accurate for single component plots.
115+
if self.numRunsAllNans > 0:
116+
text = hv.Text(0.0, 0.0, "{} runs with NaNs only".format(str(self.numRunsAllNans)),
117+
halign='left', valign='bottom')
118+
image=image*text
119+
113120
return image, self.title

0 commit comments

Comments
 (0)