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

Re: [amibroker] Intraday data chart



PureBytes Links

Trading Reference Links




You 
may be able to prevent this problem by "disabling" the first 3 writes to disk, 
this in effect would ignore the first "Apply". Regular refresh cycles should 
execute code only once. with changing data or time.
<FONT face=Arial color=#0000ff 
size=2> 
You 
can also read the time (seconds) and do not allow writes within the same second, 
you copy the time to a static variable and unless it has changed you do not 
write to disk. This is a technique i use in some code...however depedning 
on what you are doing a second may be a long time. With high volume stocks, 
those giving several ticks a second you can count ticks and only allow writes 
when (Seconds OR TickCount) has changed. Not perfect i know...but since data 
doesn't change between ticks you would never write the same data to 
disk.
<FONT face=Arial color=#0000ff 
size=2> 
<FONT face=Arial color=#0000ff 
size=2>herman.
<FONT face=Arial color=#0000ff 
size=2> 
<FONT face=Arial color=#0000ff 
size=2> 

  <FONT face=Tahoma 
  size=2>-----Original Message-----From: Ara Kaloustian 
  [mailto:ara1@xxxxxxxxxx]Sent: Thursday, July 22, 2004 2:35 
  PMTo: AB-MainSubject: [amibroker] Static 
  variables
  I tried some time ago to write trade signals to 
  disk in real time, but got multiple writes. I had both interpretaion window 
  and tooltips closed. This made the EOD vesion work OK, but not real 
  time.
   
  Problem was that I still had multiple writes for 
  each operation I wanted. ... I guess the writes were with each tick (time base 
  was 1 min) in that bar ... or some other cause...
   
  The question I have, can Static variables help 
  eliminate this problem? Any other way?
   
  Thanks
   
  AraCheck AmiBroker web 
  page at:<A 
  href="">http://www.amibroker.com/Check 
  group FAQ at: <A 
  href="">http://groups.yahoo.com/group/amibroker/files/groupfaq.html 
  


Check AmiBroker web page at:
http://www.amibroker.com/

Check group FAQ at: http://groups.yahoo.com/group/amibroker/files/groupfaq.html








Yahoo! Groups Sponsor


  ADVERTISEMENT 












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 the Yahoo! Terms of Service.