I have ~64 plot functions and practically don't add more. But their the colors are connected to Boolean variables. For example if the Boolean variable is true
then the color is red
but if false
then its green
(or sometimes transparent, fill
functions have the main role then).
The interesting is,
BooleanVariable = false
then we don't exceed that limit of 64.BooleanVariable = true
then again, we don't exceed that limit of 64.BooleanVariable = some_boolean_math_expression
the result of which is sometimes true, sometimes false, then whoops; limit is exceeded.I am confused because the expression may return with true
or false
, one of the other cases when the limit is not exceeded. It's like the script hates math (returning with true
or false
values) but accepts direct declarations of true
or false
values.
Is it a bug? Or a strange but understandable logic somehow?
Using boolean expressions results in the output being an additional output series. For example if you use a boolean expression to define the color of a plot then it results in two of the 64 limit being used, even though only one plot() is used.
c = close > open
plot(close, color = c ? color.green : color.red)