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

[amibroker] Re: Looping question



PureBytes Links

Trading Reference Links

Best answer of all, Dingo, including mine...

Jitu

--- In amibroker@xxxxxxxxxxxxxxx, "dingo" <dingo@xxxx> wrote:
> every time you use the array name as you did with volume you imply 
that
> ALL of the bars are to be used in the calc. 
>  
> when you use looping that implies that you want to work on the 
array one
> bar at a time so you should use Volume(i) to indicate which bar to 
use.
>  
> d
> 
> -----Original Message-----
> From: Jayson [mailto:jcasavant@x...] 
> Sent: Sunday, December 07, 2003 11:16 PM
> To: 1ami
> Subject: [amibroker] Looping question
> 
> 
> I am trying to get my mind wrapped around looping could some please
> explain to me why the following code does not reflect the same 
thing as
> cum(v)?
>  
> x=0;
> 
> for( i =1; i <BarCount ; i++ )
> 
> {
> 
> x = x +Volume;
> 
> }
> 
> plot(x,"Test",5);
>  
> It "seems" like I am saying " x= the last value of x plus volume" 
and
> that would continue to increment by each days volume until the last 
bar.
> Of course that is not happening at all. I am sure I am missing 
something
> simple...any help appreciated
>  
> Regards, 
> Jayson 
>  
> 
> Yahoo! Groups Sponsor	
> 
> ADVERTISEMENT
>  
> 
<http://rd.yahoo.com/SIG=12cjfu5n6/M=267637.4116732.5333197.1261774/D=
eg
> 
roupweb/S=1705632198:HM/EXP=1070943361/A=1853618/R=0/*http://www.netfl
ix
> .com/Default?mqso=60178338&partid=4116732> click here	
>  
> <http://us.adserver.yahoo.com/l?
M=267637.4116732.5333197.1261774/D=egrou
> pmail/S=:HM/A=1853618/rand=757022571> 	
> 
> Send BUG REPORTS to bugs@xxxx
> Send SUGGESTIONS to suggest@xxxx
> -----------------------------------------
> Post AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx 
> (Web page: http://groups.yahoo.com/group/amiquote/messages/)
> --------------------------------------------
> Check group FAQ at:
> http://groups.yahoo.com/group/amibroker/files/groupfaq.html 
> 
> Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service
> <http://docs.yahoo.com/info/terms/> .


------------------------ Yahoo! Groups Sponsor ---------------------~-->
Buy Ink Cartridges or Refill Kits for your HP, Epson, Canon or Lexmark
Printer at MyInks.com. Free s/h on orders $50 or more to the US & Canada.
http://www.c1tracking.com/l.asp?cid=5511
http://us.click.yahoo.com/mOAaAA/3exGAA/qnsNAA/GHeqlB/TM
---------------------------------------------------------------------~->

Send BUG REPORTS to bugs@xxxxxxxxxxxxx
Send SUGGESTIONS to suggest@xxxxxxxxxxxxx
-----------------------------------------
Post AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx 
(Web page: http://groups.yahoo.com/group/amiquote/messages/)
--------------------------------------------
Check group FAQ at: http://groups.yahoo.com/group/amibroker/files/groupfaq.html 

Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/