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

Re: [amibroker] Re: Enhancement Request - "Playback" Function



PureBytes Links

Trading Reference Links

Glen,

Volume field is an integer than can hold maximum number of: 2^31.
Your code causes overflow and that's why you get invalid results.
Use OHLC fields instead for such large numbers:

TotalTurnover = V * C;
AddToComposite(TotalTurnover,"~Turnover","X");

Best regards,
Tomasz Janeczko
amibroker.com
----- Original Message ----- 
From: "Glenn" <glennokb@xxxxxxxxxxxx>
To: <amibroker@xxxxxxxxxxxxxxx>
Sent: Saturday, January 24, 2004 1:38 AM
Subject: [amibroker] Negative composite value?


> Hi,
> 
> I have a database of about 1400 stocks and when I run an 
> Addtocomposite ie: 
> 
> TotalTurnover = V * C;
> AddToComposite(TotalTurnover,"~Turnover","V");
> 
> I'm getting some large negative numbers.
> 
> If I run an "Explore" using:
> 
> TotalTurnover = V * C;
> AddColumn(TotalTurnover,"TotalTurnover",1.3);
> Filter=1;
> 
> ...on the same database and set the range to the same date with 
> negative turnover.
> 
> I exported this to Excel and sum() the turnover, the 
> result is definately not negative.
> 
> Thanks for any help.
> 
> Cheers Glenn
> 
> 
> 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 
> 
> 
> Yahoo! Groups Links
> 
> To visit your group on the web, go to:
>  http://groups.yahoo.com/group/amibroker/
> 
> To unsubscribe from this group, send an email to:
>  amibroker-unsubscribe@xxxxxxxxxxxxxxx
> 
> Your use of Yahoo! Groups is subject to:
>  http://docs.yahoo.com/info/terms/ 
> 
> 
> 

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 

------------------------ 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
---------------------------------------------------------------------~->

Yahoo! Groups Links

To visit your group on the web, go to:
 http://groups.yahoo.com/group/amibroker/

To unsubscribe from this group, send an email to:
 amibroker-unsubscribe@xxxxxxxxxxxxxxx

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