ni.com is currently undergoing scheduled maintenance.

Some services may be unavailable at this time. Please contact us for help or try again later.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

numeric series

Is there any function which gives a summarized serie from a selected range?
 
For example, in my bluetooth test, I can measure channels from 0 to 78. I select, for instance, 0, 2, 10, 11, 12, 13, 14, 15, 20, 21, 22, 23, 24, 25, 30.
                                                    In the summary, I would like to get a more compact view, like: 0, 2, 10-15, 20-25, 30
 
Thanks in advance.
 
Gatet
0 Kudos
Message 1 of 6
(3,156 Views)
hi Gatet
I havn't found any function that performs the requested operation !!
Why don't you build  it?
Possible solution ==>pseudo code
1:string data to array
2:use a for loop to index  an array (True /false ), shift registers to hold salient data
3:extract salient data from true/false data with respect to string data array.Decimate  all non essential cells
4 reverse process- array to string

Should give you some ideasSmiley Indifferent

chow
xseadog

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

Sorry, Chow, but I don´t understand step three. WOuld you be so kind to explain it a bit?

 

Thanks

0 Kudos
Message 3 of 6
(3,149 Views)
Hi Gatet
vi produces T/F Array
Now you have to link array data with string array data to finish with a sequence.
 
NB: in present form it produces a false 'true'on hte last  cell (comparision)
 
hope that sets you on your way
chow
 
XSEADOG
0 Kudos
Message 4 of 6
(3,137 Views)
Here is the solution!
 
Thanks for your help, Chow

 

Mensaje editado por Gatet

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

It was not correct for only one value selection, and also not with the first selection.

Now is better

0 Kudos
Message 6 of 6
(3,110 Views)