10-16-2017 05:56 AM
Hi everyone, i have created a VI that read data from a file. My X-axis display the time from 0-120s and my Y axis is the amplitude of the signal. I want to be able to display the signal from a specific point of time and not sure how to do it. In order words, when i choose 0-3seconds, the graph will show the signal from that range.Appreciate all suggestions!
Subsequently, i will like to display individual signals on the graph from 120spectra that i have inside the graph.
Attached below is the VI as well as text file of my signal data.
Solved! Go to Solution.
10-16-2017 06:20 AM
1. Just use a property node for the XY Graph. The properties you are looking for are X Scale->Range->Maximum and X Scale->Range->Minimum.
2. Right-click on the plot legend (where it shows the colors for each plot. There is an option for Plot Visibility Checkbox. Enable that and it will do the work on your Boolean array. You might also want to turn on the Vertical Scrollbar for the plot legend.
With these two things, you will no longer need to manipulate the data and rewrite to the graph. 1 is just a simple property write when your scale needs changed. 2 requires no code on your part.
10-16-2017 06:52 AM
Hi crossrulz! I understand your suggestion and i created the property node but whenever i input a range the graph will flicker to that time range and back to the original and keep on flickering between the two. Is this due to the while loop? Sorry i am rather new to labview. But thank you so much, your suggestion is great!
Attached below is the new VI with XY property node.
10-16-2017 07:11 AM
Hi Luca,
switch off the x axis autoscaling of the graph…
You should call this property node only, when there is a value change event of the XScale.Range-controls! No need to set those properties each 50ms in the timeout event…
10-16-2017 07:24 AM
Hi GerdW! Thank you for your suggestion, worked like a charm! Now my program is able to display the signals at a particular time.
As for the second part of my problem, anyone has suggestions on how i can just focus on one particular signal? Now i have 120 different signals. Is there any way to focus on each individual signal so i can perform peak to peak calculations on it. I tried using event structure with remove array data but it proves to be inefficient.
10-16-2017 09:10 AM
@LucaSoup wrote:
As for the second part of my problem, anyone has suggestions on how i can just focus on one particular signal? Now i have 120 different signals. Is there any way to focus on each individual signal so i can perform peak to peak calculations on it. I tried using event structure with remove array data but it proves to be inefficient.
Use an enum or ring to have the user select which signal to do the calculations on. Then you just use Index Array to isolate the signal.
10-16-2017 11:47 AM
Hi Crossrulz! I have tried to follow your suggestions but ran into some problems. If i am not wrong, you are suggesting i put the signal through an index array and display the signal through (rows/column) by using an Enum probe. However, now i cannot connect back to XY graph due to different dimensions of array.
Any tips on where i am doing wrong, Thanks! (attached below is my failed try VI)