NexusFi: Find Your Edge


Home Menu

 





How to cancel and reorder within 1 min intrabar?


Discussion in NinjaTrader

Updated
      Top Posters
    1. looks_one ericson with 3 posts (0 thanks)
    2. looks_two vvhg with 2 posts (0 thanks)
    3. looks_3 Quick Summary with 1 posts (0 thanks)
    4. looks_4 MrYou with 1 posts (0 thanks)
    1. trending_up 1,575 views
    2. thumb_up 0 thanks given
    3. group 3 followers
    1. forum 6 posts
    2. attach_file 0 attachments




 
Search this Thread

How to cancel and reorder within 1 min intrabar?

  #1 (permalink)
 ericson 
Sacramento, CA
 
Experience: Advanced
Platform: NinjaTrader
Broker: NA
Trading: Stocks, Forex
Posts: 64 since Nov 2013
Thanks Given: 14
Thanks Received: 19

So im trading EURUSD with limit orders and sometimes they are canceled, mostly selling short or selling. I want the best limit order price within the 1 min bar. I want to chase it within the bar say every 5 or 10 seconds and not wait until the end of bar to reorder.

I cant find a way to save the Iorder variable such as for a 1 sec onbarupdate interval to conduct such a method. Every onbarupdate resets all the internal script variables.

Neither using onorderupdate because its not until the next bar is it canceled and then reordered.

There seems no way around this.

Started this thread Reply With Quote

Can you help answer these questions
from other members on NexusFi?
How to apply profiles
Traders Hideout
Pivot Indicator like the old SwingTemp by Big Mike
NinjaTrader
Exit Strategy
NinjaTrader
Better Renko Gaps
The Elite Circle
Increase in trading performance by 75%
The Elite Circle
 
Best Threads (Most Thanked)
in the last 7 days on NexusFi
Just another trading journal: PA, Wyckoff & Trends
33 thanks
Tao te Trade: way of the WLD
24 thanks
My NQ Trading Journal
14 thanks
HumbleTraders next chapter
11 thanks
GFIs1 1 DAX trade per day journal
11 thanks
  #3 (permalink)
 
MrYou's Avatar
 MrYou 
NC, USA
 
Experience: None
Platform: None Yet
Trading: Guitar
Posts: 403 since Jun 2011
Thanks Given: 618
Thanks Received: 196


Execute your trades on a secondary time/data series such as a 5 or 10 seconds data series.

Reply With Quote
  #4 (permalink)
 ericson 
Sacramento, CA
 
Experience: Advanced
Platform: NinjaTrader
Broker: NA
Trading: Stocks, Forex
Posts: 64 since Nov 2013
Thanks Given: 14
Thanks Received: 19

That wont work because i need COBC = true and the small interval in onbarupdate the IOrder variable is lost on each update. Again, im at a loss here.

Started this thread Reply With Quote
  #5 (permalink)
 
vvhg's Avatar
 vvhg 
Northern Germany
 
Experience: Intermediate
Platform: NT
Trading: FDAX, CL
Posts: 1,583 since Mar 2011
Thanks Given: 1,016
Thanks Received: 2,824

You could either use a timer (easy) or write your own custom event (more work, but the elegant way) for this scenario.

vvhg

Hic Rhodos, hic salta.
Reply With Quote
  #6 (permalink)
 ericson 
Sacramento, CA
 
Experience: Advanced
Platform: NinjaTrader
Broker: NA
Trading: Stocks, Forex
Posts: 64 since Nov 2013
Thanks Given: 14
Thanks Received: 19

Ive looked into trigger custom event but cant make it work. Can you point me in the right direction to do this? Sample code?

Started this thread Reply With Quote
  #7 (permalink)
 
vvhg's Avatar
 vvhg 
Northern Germany
 
Experience: Intermediate
Platform: NT
Trading: FDAX, CL
Posts: 1,583 since Mar 2011
Thanks Given: 1,016
Thanks Received: 2,824


ericson View Post
Ive looked into trigger custom event but cant make it work. Can you point me in the right direction to do this? Sample code?

Here is one example:

There are also 100s of examples when you search via google as it's plain C# stuff.

Vvhg

Hic Rhodos, hic salta.
Reply With Quote




Last Updated on February 19, 2014


© 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