CinnamonMetal Posted September 6, 2018 Share Posted September 6, 2018 If a vector has a length, how do you zero out those lengths as I'm iterating over all the vector lengths but I want those a specific length to be zeroed out, giving them a vector of 0 Quote Link to comment Share on other sites More sharing options...
woodenduck Posted September 6, 2018 Share Posted September 6, 2018 Multiply by zero if condition is met. if(length(v@vectorName) > threshold) { v@vectorName *= 0; } Quote Link to comment Share on other sites More sharing options...
animatrix Posted September 6, 2018 Share Posted September 6, 2018 Just assign 0 to them afterwards. myvector = 0; Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.