Haifa Israel
Posts: 2 since May 2015
Thanks Given: 0
Thanks Received: 1
|
Hi,
I have a problem regarding redefine a variable.
in TOS you can reference a variable only once in a script.
i define a variable to be a counter. if < condition > is met i add 1 to it
---------------------------------------------------------------------
rec cnt = if <condition> then cnt[1]+1 else 0;
---------------------------------------------------------------------
now, if cnt equal to 5 i want to use the plot command and then zero cnt variable.
---------------------------------------------------------------------
plot aaa = if cnt == 5 then low else Double.NaN;
----------------------------------------------------------------------
I don't know how to zero the cnt variable because i can not redefine again.
any one has any solution ? or rethinking about my problem.
Thanks
|