LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Filtering data with case structure and auto-indexing

I am trying to filter the "detected frequencies" detected by my program by not auto-indexing them into the final array in case they don't fall between the 100-1000 Hz limit. To do that, I'm using the code in the picture below:

logolepser_1-1622670670465.png

However, when the condition is "False", I'd like my case structure to do nothing and just skip to the next element in the array. But I can't just leave the "False" window of the case structure blank, otherwise the program won't run.
Is there a "skip" function I can use? Essentially, I'm trying to mimic what you'd do in python: 

 

for value in list:
  if condition(value)==True:
     data.append(value)
  else:
     continue

 



0 Kudos
Message 1 of 2
(721 Views)

Are you doing anything in the true case?

 

If you are doing nothing if True but including it in the final array, and doing nothing in False, but not including in the final array.  Then do this.

 

Get rid of the case structure.  Right click on the Auto-Indexing tunnel and pick Conditional Terminal.

Wire up the boolean wire to that.

Message 2 of 2
(711 Views)