Community
Bifrost Forum
Welcome to the Bifrost Forum. This is the place for artists using Bifrost to ask and answer questions, browse popular topics, and share knowledge about creating effects procedurally using Bifrost. You can also visit the Bifrost Community on AREA to download an array of ready-to-use graphs, read Bifrost news and updates, and find the latest tutorials.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

find all values in range in array

1 REPLY 1
SOLVED
Reply
Message 1 of 2
sklauss
340 Views, 1 Reply

find all values in range in array

Hi,

 

I have an array of values and want to output an array of the indices for values in a given range.

 

Let's say I have [1,9,3,4,2,6,7,5,9,4] and want the indices for all in range between 3 and 4, so

I would expect [2,3,9]

 

Any tips?

Cheers

1 REPLY 1
Message 2 of 2
mjcg91
in reply to: sklauss

you can use "within_bounds" followed by "find_all_in_array". Set the "in_bounds" output port to the "array" port of find_all_in_array, and set the value to find to be "true". This way, it will return all indices that are within the range you've defined.

Maxime Jeanmougin - Technical Artist
https://maximejeanmougin.com

Join the Bifrost Addicts community on Discord:
https://discord.gg/bifrost-addicts

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report