NexusFi: Find Your Edge


Home Menu

 





MC Multiple-instrument duplicate rows


Discussion in MultiCharts

Updated
    1. trending_up 1,651 views
    2. thumb_up 3 thanks given
    3. group 1 followers
    1. forum 3 posts
    2. attach_file 0 attachments




 
Search this Thread

MC Multiple-instrument duplicate rows

  #1 (permalink)
adam081527
Hong Kong
 
Posts: 10 since Feb 2012
Thanks Given: 7
Thanks Received: 4

i use IB as broker and windows Vista as operating system, everything is good, but i have a little problem on printing data print to log,

while im printing 1minute closing price, there is a problem when i print multi-instrument to the log on the same row,

for example, printing crude oil (IB: CLJ2) and E-mini S&P (ESH2),
duplicated rows come out like below,

910.00 106.57 2632.00
912.00 106.62 2632.75
913.00 106.62 2632.25
914.00 106.62 2632.25
915.00 106.63 2632.25
916.00 106.66 2632.25
916.00 106.66 2632.25
917.00 106.63 2632.50
917.00 106.63 2632.50
918.00 106.63 2632.00
918.00 106.63 2632.00

for historical data, no problem, but when run in real time, it keep on showing duplicated data,
then the indicator values make unnecessary changes,
just like above data, i start the program on 091530, then data before is fine, but not afterwards,

im not sure if the problem is because of the 2 products from different exchanges, so they have time gaps??

any suggestions how to settle this problem??

much appreciate,

ad

Reply With Quote

Can you help answer these questions
from other members on NexusFi?
Request for MACD with option to use different MAs for fa …
NinjaTrader
My NT8 Volume Profile Split by Asian/Euro/Open
NinjaTrader
ZombieSqueeze
Platforms and Indicators
NexusFi Journal Challenge - April 2024
Feedback and Announcements
 
Best Threads (Most Thanked)
in the last 7 days on NexusFi
Retail Trading As An Industry
58 thanks
Battlestations: Show us your trading desks!
56 thanks
NexusFi site changelog and issues/problem reporting
48 thanks
What percentage per day is possible? [Poll]
31 thanks
GFIs1 1 DAX trade per day journal
29 thanks

  #2 (permalink)
 
Jura's Avatar
 Jura   is a Vendor
 
Posts: 775 since Apr 2010
Thanks Given: 2,352
Thanks Received: 690


adam081527 View Post
for historical data, no problem, but when run in real time, it keep on showing duplicated data,

It might be that the indicator gets printed on the close of Data1 and on the close of Data2, or the Print() statement gets executed more than once per bar.

Try something like the following (which would solve both possible causes):

 
Code
if (BarStatus(1) = 2) then begin

    Print("Now printing only at bar close for Data1.");

end;

Reply With Quote
The following user says Thank You to Jura for this post:
  #3 (permalink)
adam081527
Hong Kong
 
Posts: 10 since Feb 2012
Thanks Given: 7
Thanks Received: 4



Jura View Post
It might be that the indicator gets printed on the close of Data1 and on the close of Data2, or the Print() statement gets executed more than once per bar.

Try something like the following (which would solve both possible causes):

 
Code
if (BarStatus(1) = 2) then begin

    Print("Now printing only at bar close for Data1.");

end;

thank you very much, will try

Reply With Quote
The following user says Thank You to adam081527 for this post:
  #4 (permalink)
adam081527
Hong Kong
 
Posts: 10 since Feb 2012
Thanks Given: 7
Thanks Received: 4


Jura View Post
It might be that the indicator gets printed on the close of Data1 and on the close of Data2, or the Print() statement gets executed more than once per bar.

Try something like the following (which would solve both possible causes):

 
Code
if (BarStatus(1) = 2) then begin

    Print("Now printing only at bar close for Data1.");

end;

hi Jura,

it works very well,

much appreciate,
ad

Reply With Quote
The following user says Thank You to adam081527 for this post:





Last Updated on March 11, 2012


© 2024 NexusFi™, s.a., All Rights Reserved.
Av Ricardo J. Alfaro, Century Tower, Panama City, Panama, Ph: +507 833-9432 (Panama and Intl), +1 888-312-3001 (USA and Canada)
All information is for educational use only and is not investment advice. There is a substantial risk of loss in trading commodity futures, stocks, options and foreign exchange products. Past performance is not indicative of future results.
About Us - Contact Us - Site Rules, Acceptable Use, and Terms and Conditions - Privacy Policy - Downloads - Top
no new posts