LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How do I mark a "not measurable" event on a chart history?

I have an application which is working very well and takes measurements - continuously plotting a result on a chart. The chart history is typically a 100 or so measurements. I plot on the chart both an upper and lower tolerance limit, hence the measurment plot should hopefully stay between the two (straight lines) limits.
 
Occasionally a sample is "missing" and when this happens a "measurement" of zero is given. This is currently displayed on the chart as a sudden drop to zero. The users like this as it shows them clearly that the sample was missing. All OK so far, however...
 
On rare occasions a sample is present and is measured but for reasons I will not go into we know (and the software can determine) that the measurement result is actually invalid. This situation I call "not measurable" in that although a sample is present it actually cannot be properly measured. The question is this; how do I show this on my chart history?The chart history plot is by far the most looked at display of data for the users. I realise that I could show a message box saying "not measurable" (and intend to do so) but this would only last for that measurement cycle. How do I "mark" the chart to show that there was a sample but that it was not measurable.
 
I don't particularly want to use a zero value because that is being used quite nicely for the "no sample" situation. Also I don't want to simply not plot anything because the fact that the sample was "not measurable" is potentially very important indeed. Ideally what I would like is to put a marker, say a thick vertical line at the position where the invalid measurment is, in order to both block it out to show that it is wrong and also show there actually was a sample there in the first place.
 
Any ideas as to how I can do this? Sorry this is a bit wordy!
 
Regards
 
Kevin
0 Kudos
Message 1 of 5
(2,997 Views)
Hello Kevin,

just put a second line of data into your chart. This 2nd line is kind of boolean: 0=sample ok, 1=not measured. Configure this plot to show as steps instead of lines and adapt the values 0/1 to your sample data to span the full range. This way you get vertical bars in the background of your sample data...

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
Message 2 of 5
(2,991 Views)
Thanks,
 
I'll try that or something smiliar in any case.
 
Regards
 
Kevin
0 Kudos
Message 3 of 5
(2,985 Views)
I like Gerds solution (could be three 'lines' with different  colors for "missing", "not measurable", "OUT OF RANGE" )
 
Another way: a (SGL or DBL) value of NaN (Not a Number, you can get it as a constant Smiley Wink) will not be shown on the chart.
 
Greetings from Germany
Henrik

LV since v3.1

“ground” is a convenient fantasy

'˙˙˙˙uıɐƃɐ lɐıp puɐ °06 ǝuoɥd ɹnoʎ uɹnʇ ǝsɐǝld 'ʎɹɐuıƃɐɯı sı pǝlɐıp ǝʌɐɥ noʎ ɹǝqɯnu ǝɥʇ'


0 Kudos
Message 4 of 5
(2,977 Views)

Hi

 

I have come up with a quick fix for using a chart which might give you a few ideas. This is just a quick fix and isn’t very nice at all. The green dots are meant to represent the immeasurable data, I have just triggered them by a set of limits. You would be better of using an XY plot and an array which you constantly up date. Using an XY graph will give you a lot more options such as using cursors to mark certain points.

 

I have attached my quick fix and an example of using text on an XY graph

 

Hope this at least gives you some ideas

 

Tim

 

AE NI UK and Ireland

Download All
0 Kudos
Message 5 of 5
(2,953 Views)