Postby ABC » 19 Aug 2013
From your code it appears that volume is a function. Which would be weird, as the editor shouldn't let you use a reserved word for a variable name. If it's a function it is not a build in one and it would be hard to tell what you need to change exactly (using Close[1] would be a guess).
Normally you can simply use volume[1] to receive the volume from the previous bar with the reserved word volume.
For tick and volume-based charts, and time-based charts with resolutions of 24 hours or less you need to use the reserved word "tick" to receive the volume information from those chart resolutions.
Regards,
ABC