Welcome Guest, please sign in to participate in a discussion. | Search | Active Topics | |
Registered User Joined: 11/6/2007 Posts: 28
|
Seems like the price count is always 11 in filter. I'm not sure if this is just me. It seems to be true for all stocks. I did a trivial condition and put a debug log like this
Me.log.info("Plot count " + price.Count.tostring())
I am using EOD data and did a wipe out on the data earlier and reinstall it back. I am able to draw the condition on the chart though.
|
|
Registered User Joined: 11/6/2007 Posts: 28
|
Worden staff,
comments? This should be easily verifiable.
|
|
Administration
Joined: 9/18/2004 Posts: 3,522
|
The reason is that 11 is the default size we try to trim down a calculation to for performing column calculations.
Try this instead:
if price.count < 50 then
return Single.Nan
end if
me.log.info("Plot Count" + Price.Count.tostring())
Ken Gilb (Kuf) Chief Software Engineer - Worden Brothers Inc. Try/Catch - My RealCode Blog
|
|
Registered User Joined: 11/6/2007 Posts: 28
|
It gives compile error "return statement in a sub or set cannot return a value"
Anyway, If price count is set to 11 for filter. I would argue that it is semantically wrong. It is like saying "only 11 bars is available."
|
|
Guest-1 |