[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [amibroker] Sum Reference Not Same as Simply Adding Previous Data Points Manually


  • Date: Fri, 05 Mar 2010 19:11:45 +0100
  • From: Reinsley <reinsley@xxxxxxxx>
  • Subject: Re: [amibroker] Sum Reference Not Same as Simply Adding Previous Data Points Manually

PureBytes Links

Trading Reference Links





Hi,

Not tested, what about this ?

CumVolume = Sum(Volume,4) - Sum(Volume,1);

Best regards


Le 05/03/2010 17:43, davemabe2000 a écrit :
 

I'm trying to add the volume of the three previous bars (not including the current one) in my backtest.

If I sum them up "manually" I get one value:

VolumeSumA = Volume[i-1] + Volume[i-2] + Volume[i-3];

But when I try using Sum and Ref to do it I get a different value for some reason.

VolumeSumB = Sum(Ref(Volume, -1), 3);

But VolumeSumA != VolumeSumB.

What should I be using for Sum and Ref to get it to work properly and equal VolumeSumA above?




__._,_.___


**** IMPORTANT PLEASE READ ****
This group is for the discussion between users only.
This is *NOT* technical support channel.

TO GET TECHNICAL SUPPORT send an e-mail directly to
SUPPORT {at} amibroker.com

TO SUBMIT SUGGESTIONS please use FEEDBACK CENTER at
http://www.amibroker.com/feedback/
(submissions sent via other channels won't be considered)

For NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG:
http://www.amibroker.com/devlog/





Your email settings: Individual Email|Traditional
Change settings via the Web (Yahoo! ID required)
Change settings via email: Switch delivery to Daily Digest | Switch to Fully Featured
Visit Your Group | Yahoo! Groups Terms of Use | Unsubscribe

__,_._,___