LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How can I find the local maximum in each interval from a graph?

I have very less experience in labview and need some helps. I am currently using Labview 2013.

 

I am analysing a very big data file. I want to find the  values of the local maximum (the peak) in every 1000 data points. Is there anyway to do it?

 

I also want to have a control on when to start finding the local maximum point (after 10000 data points) and when to end it ( at 30000 data points)

 

The attachment is a very similar graph of what I am analysing.

 

Thank you very much.

 

0 Kudos
Message 1 of 6
(3,489 Views)

Please, can anyone help?

 

Do I need to write a C program and then import to labview or I can use the built-in functions from the labview?

 

Many thanks

0 Kudos
Message 2 of 6
(3,471 Views)

Hi John,

 

save that Excel spreadsheet as CSV file (form Excel).

 

The use ReadFromSpreadsheetFile to load the data into LabVIEW. Now you get an array of data and you can do anything with it.

 

- You might use a loop to pick an ArraySubset of each 1000 datapoints and analyze it.

- You might use numeric controls to provide an input for the user...

 

Where's your problem? It seems you already know where the goal is...

And try to THINK DATAFLOW! You don't want to analyze data from a graph, you want to analyze spreadsheet data. A graph is just a data sink (in LabVIEW)...

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 3 of 6
(3,451 Views)

Hi GerdW

 

I have tried your way. I created a sub-array starting from 10246 index of the original array and the length is 1000. I also managed to find the max and min from the array. But I have troubles in the loop function. What loop function should I use and how to connect them? I have tried For loop, but I can only show the first array. How can I tell the computer to do the next iteration from 11246 and so on?

 

Best regard

John

0 Kudos
Message 4 of 6
(3,428 Views)

Hi GerdW

 

I forgot to attach the VI file in the last reply, I have done that in this one.

 

Thx

0 Kudos
Message 5 of 6
(3,424 Views)

Hi John,

 

you should go through those free online LabVIEW 101 courses to learn how to use loops (and autoindexing) in LabVIEW...

 

check.png

Do you get the idea?

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
Message 6 of 6
(3,406 Views)