NexusFi: Find Your Edge


Home Menu

 





timed exit


Discussion in Platforms and Indicators

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




 
Search this Thread

timed exit

  #1 (permalink)
sr114
Kolkata+India
 
Posts: 27 since Aug 2012
Thanks Given: 10
Thanks Received: 1

Hello Boarders

in developing intraday system how we could use the concept of timed exit at a certain time of the trading hours?
it must be applicable for range bars also beside the actual time frame ( for any tf its easy but for range bars - what to do?)

for example - we take a simple ma crossover system of a fast average and slow average.

f=fast average;
s=slow average;

so the buy and sell will be

buy=Cross(f,s);
sell=Cross(s,f); // and exit at 2300 hrs;

plot (C,"",colorgreen, 64);
PlotShapes( IIf( Buy, shapeUpArrow, shapeNone ), 51 );
PlotShapes( IIf( Sell, shapeDownArrow, shapeNone ), 42);


now if to implement that the sell condition also have a timed exit part - i.e. at a certain time - lets say at 2300 hrs - all active trade will be closed - be it buy or sell.

what is the code to be used for the timed exit?

in a breakout system, what will be a good cover and exit condition?

breakout condition for bur or sell ( cover/exit logic, code needed for this buy/sell trade)

Buy =Cross( C, Ref( HHV(H,Buyperiods), -1 )) ;
Sell =Cross(Ref(LLV(Low,Sellperiods),-1),C) ;


what condition can we apply here in the buy or sell for a good cover or exit from the trade?


rgds
sr

Reply With Quote

Can you help answer these questions
from other members on NexusFi?
Better Renko Gaps
The Elite Circle
Exit Strategy
NinjaTrader
NT7 Indicator Script Troubleshooting - Camarilla Pivots
NinjaTrader
ZombieSqueeze
Platforms and Indicators
Trade idea based off three indicators.
Traders Hideout
 
Best Threads (Most Thanked)
in the last 7 days on NexusFi
Diary of a simple price action trader
26 thanks
Just another trading journal: PA, Wyckoff & Trends
25 thanks
Tao te Trade: way of the WLD
23 thanks
My NQ Trading Journal
16 thanks
HumbleTraders next chapter
9 thanks
  #2 (permalink)
 dwitkin 
Reston, Virginia
 
Experience: Advanced
Platform: ThinkOrSwim, AmiBroker
Broker: ThinkOrSwim, TradeStation
Trading: Metals, Grains
Posts: 7 since Nov 2010
Thanks Given: 18
Thanks Received: 3

If I'm understanding what you want, this should do what you are looking for...

Defines when to enter trades, and when to exit.

 
Code
/* Define trading start and end times. Don't take trades outside these times */
/* Include in entry/exit rules only when trading equity markets */
FirstTradeTime = 094500;				// Earliest time to take a trade
LastTradeTime = 153000;					// Latest time to take new trades
ExitAllPositionsTime = 154500;		// Exit all trades
 
Code
/* Buy & Sell Section */

Buy = 	... AND
		(TimeNum() >= FirstTradeTime AND TimeNum() <= LastTradeTime );

// For US equities markets, exit when the current time is greater than a certain time of Day (e.g., > 15:30)
Sell = ... OR
	 TimeNum() >= ExitAllPositionsTime;
And just use the same logic for the Sell Short and Cover.

Reply With Quote
Thanked by:
  #3 (permalink)
sr114
Kolkata+India
 
Posts: 27 since Aug 2012
Thanks Given: 10
Thanks Received: 1



dwitkin View Post
If I'm understanding what you want, this should do what you are looking for...

Defines when to enter trades, and when to exit.

 
Code
/* Define trading start and end times. Don't take trades outside these times */
/* Include in entry/exit rules only when trading equity markets */
FirstTradeTime = 094500;				// Earliest time to take a trade
LastTradeTime = 153000;					// Latest time to take new trades
ExitAllPositionsTime = 154500;		// Exit all trades
 
Code
/* Buy & Sell Section */

Buy = 	... AND
		(TimeNum() >= FirstTradeTime AND TimeNum() <= LastTradeTime );

// For US equities markets, exit when the current time is greater than a certain time of Day (e.g., > 15:30)
Sell = ... OR
	 TimeNum() >= ExitAllPositionsTime;
And just use the same logic for the Sell Short and Cover.

Hi

thanx for the prompt reply

for a time frame based afl this logic will work, but for a range bar type it is not working?
as range bars are time independent

also cud u specify a good cover/exit logic in this case , then the time based exit can be over rided

rgds
sr

Reply With Quote




Last Updated on January 16, 2013


© 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