xelParticipant
Average
Hi!
Is there a way in ProBuilder to generate a variable, say “V” with “1” from a series that have values of “0” or “NotANumber” ?
As a example: V = if volume == 0 or “not a number” then 1
Thanks!
You can’t have string affected to variable. So your “V” variable would never record something else than numbers.
Maybe you could post an example of what you expect exactly and I’ll could be more precise 🙂
xelParticipant
Average
Im porting one of my indicators that use Volume to plot data, but some tickers do not have volume reported or just as cero in TV. (Some Indexes, Forex, etc). So, for this kind of situations, I want to report volume as 1 given multiplication weighting in my algorithm.
xelParticipant
Average
I don’t know if this statement works, ProBuilder editor doesn’t give me any error by now. Not finished yet but…
Vo = volume
IF Vo = 0 or Vo = undefined then
Vo = 1
ENDIF
You don’t have to test if Vo = undefined. The platform would never return this kind of value. If there are no values, then the variable would return 0. See my example in the picture below on forex.
xelParticipant
Average
GREAT! That will do the trick!
Thanks again Nicolas!