I’m trying to use CALL to get the return of an indicator into a strategy but I just can’t get it to work. Every time I try to run the strategy I get this error message:
The CALL instruction is written like this:
1
x,y=call"Self Op x2"[1]
The indicator does not have any parameters that need to be set so my first try didn’t have the [1] and I thought that might be the problem – so I added one called ‘dummy’ and used it like this but it still doesn’t work:
1
2
3
4
5
ifdummy=1then
(indicatorcode)
endif
I know it must be something obvious – I don’t use CALL very much so I’m assuming operator error on this one!
Because your indicator needs to know what price serie should be calculated. So, you have to add (close) or (medianprice) for instance at the end of your CALL expression.