Page 1 of 1

a way to strip 0 (or any specific) values away from array?

Posted: 12 Nov 2019, 18:14
by x.iso
Basically, if I have an array where only few indexes are active and have non-zero value, and I want to track only indexes with those active values, I have to remove 0 values and make array compact. But I can't come up with solution to that, for instance I could use Remove Duplicate module, which would get rid of 0 values, but it would also remove any matching values which can happen as well and I don't want that. Having logic ">" module can give me array of 'gates', but The 'Pass' module doesn't work with arrays and I can't find what else to use to filter out 0 values.

Re: a way to strip 0 (or any specific) values away from array?

Posted: 12 Nov 2019, 21:19
by nay-seven
Array delete will do the job ?

Re: a way to strip 0 (or any specific) values away from array?

Posted: 13 Nov 2019, 08:41
by x.iso
🤦‍♂️ oh man, how did I miss it? sure, that's exactly what I needed.

Re: a way to strip 0 (or any specific) values away from array?

Posted: 27 Nov 2019, 12:37
by oli_lab
a size 0 array on the input ?