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

Re: [amibroker] Running total array help



PureBytes Links

Trading Reference Links

Ara, Doesn't  CUM(array) do this?

----- Original Message ----
From: Ara Kaloustian <ara1@xxxxxxxxxx>
To: amibroker@xxxxxxxxxxxxxxx
Sent: Friday, February 16, 2007 1:44:46 PM
Subject: Re: [amibroker] Running total array  help

have to do it in a loop

for (i=1; i<=Lastvalue(Barindex()); i++)
{
newarray[i] = myarray[i] + myarray[i-1];
}

----- Original Message ----- 
From: "NickCivit" <nickcivit@xxxxxxxxx>
To: <amibroker@xxxxxxxxxxxxxxx>
Sent: Friday, February 16, 2007 8:30 AM
Subject: [amibroker] Running total array help


> Hi, I am new to programing and would like to create a running total of 
> some numbers in an array. Example:
> 
> MyArray = (30,40,-20,-10);
> Result =(30,70,50,40);
> 
> AddColumn(Result,"Result  ");
> 
> Would appreciate any help,
> 
> Nick C.
> 
> 
> 
> Please note that this group is for discussion between users only.
> 
> To get support from AmiBroker please send an e-mail directly to 
> SUPPORT {at} amibroker.com
> 
> For NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG:
> http://www.amibroker.com/devlog/
> 
> For other support material please check also:
> http://www.amibroker.com/support.html
> 
> Yahoo! Groups Links
> 
> 
> 


Please note that this group is for discussion between users only.

To get support from AmiBroker please send an e-mail directly to 
SUPPORT {at} amibroker.com

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

For other support material please check also:
http://www.amibroker.com/support.html
 
Yahoo! Groups Links








Content-Description: "AVG certification"
No virus found in this incoming message.
Checked by AVG Free Edition.
Version: 7.5.441 / Virus Database: 268.18.1/690 - Release Date: 2/16/2007 2:25 PM