Topic: How to force positions closed at 21:00 GMT and/or week close?

I've been wrangling with this all weekend and I'm stuck. I've read the User Manual a couple times and also searched the forum.

Is it possible to use something like:
Closing Point-> Exit Hour @ 21

...IN ADDITION to other exit criteria?  For example, I would like the Generator to find the best closing parameters, but also (additionally) ensure a hard close at GMT 21:00, or alternatively Fridays @ GMT 21:00.

I thought it might be possible to do this with Logical Groups, but so far I haven't quite figured out how to make this work.

Basically, my objective is to force all positions closed at either 21:00 GMT daily, or possibly just 21:00 GMT on Fridays. I don't want to hold positions over the weekend.

Perhaps the software can't do this yet? Everything I've read seems to indicate that if I use Exit Hour, then there can be no other closing parameters.

Thanks in advance for your help.

Re: How to force positions closed at 21:00 GMT and/or week close?

this thread may have something you can use:
http://forexsb.com/forum/topic/2228/day-of-week-exit/

Re: How to force positions closed at 21:00 GMT and/or week close?

krog wrote:

this thread may have something you can use:
http://forexsb.com/forum/topic/2228/day-of-week-exit/

Thanks krog. I did read through this thread but I think this is still the same issue as before.

Please correct me if I'm wrong -- it seems that FSB can only have one closing point. I think what I'm looking for is a logic of OR --- so it could close at [Generated combination of conditions] OR [Exit Hour before GMT 21]

Through playing around with this, I have been able to generate several profitable strategies that trade M1 timeframe and use only that single closing point of Exit Hour. It works to accomplish what I want (ie, get out of the market by 4pm New York close each day) but I think the overall strategy misses additional opportunities that could be had (ie daytrading) if there were other closing conditions.

I do use Perm TP/SL/BE settings, so on occasion the strategy can get 2 or 3 trades in a single day. But trading on the M1 timeframe, seems like a strategy should be able to get many more trades throughout the day if it had an additional closing criteria.

Another thing that could be helpful is a closing point that would be adjustable by time increment. For example, instead of just "Exit Hour before GMT 21"... how about:

Exit at time:
minute bar close increment:  5, 10, 15, 30, 60
start hour:  0-24
end hour:  0-24

For example, if I set it to "15", then it could force a close every 15 minutes. This would allow positions to run for a max of 15 minutes and then reset to allow another entry. These settings would also give me the close by GMT 21 by default, since they would all trigger a close at the top of the hour.

Re: How to force positions closed at 21:00 GMT and/or week close?

Hi dusktrader,
Could you check, is this with indicator "Exit Hour" or with "Day of Week Exit"?

Just a guess, but it sounds like you are describing Exit Hour -- it is the closing point of the trade, and you cannot add other closing logic slots to it.

Day of Week Exit -- add "Bar Closing" slot to the closing logic, then you can see Day of Week Exit indicator. Then, since it's with Bar Closing, you can add other closing indicators and change the logical groups; if they're different groups they should behave as logic "OR".

For the periodicity indicator, I'm working at that now, hope I can get something posted soon.

5 (edited by dusktrader 2012-02-22 22:43:39)

Re: How to force positions closed at 21:00 GMT and/or week close?

krog wrote:

Hi dusktrader,
Could you check, is this with indicator "Exit Hour" or with "Day of Week Exit"?

Just a guess, but it sounds like you are describing Exit Hour -- it is the closing point of the trade, and you cannot add other closing logic slots to it.

Yes I was referring to the "Exit Hour" indicator in my above post

Day of Week Exit -- add "Bar Closing" slot to the closing logic, then you can see Day of Week Exit indicator. Then, since it's with Bar Closing, you can add other closing indicators and change the logical groups; if they're different groups they should behave as logic "OR".

Awesome! I think this is exactly what I wanted. I get confused about when indicators appear and disappear ... I know there is a logical reason but I haven't quite grasped it yet. But, in my preliminary test, I believe this does exactly what I wanted: to allow Generator to come up with creative new closing strategies, while always forcing a Friday 4pm ET close (GMT 21).

I'm including a screenshot below of how I set this up in case others are also wondering. I just locked the "Day of Week Exit" condition while Generator runs.

For the periodicity indicator, I'm working at that now, hope I can get something posted soon.

Wow, that would be sweet!  Thanks for looking into this. Especially for a day-trading bot, I think the more frequently that you can force an exit, the more opportunities you have to take good trade setups. I'm excited to try it out!

Post's attachments

day-of-week-exit.png
day-of-week-exit.png 3.57 kb, file has never been downloaded. 

You don't have the permssions to download the attachments of this post.

Re: How to force positions closed at 21:00 GMT and/or week close?

Oh ok, just need to point out two more things for this indicator:
From hour -- hour part of time; From min -- minute part of time. As in the screenshot, you have "21:21" -- change "From min" to 0.
Also, (incl) means "inclusive", so includes that time, (excl) means "exclusive", so before that time. I think From Friday - To Friday will be every day. Change To (excl) to Saturday.
It's best to set the From time a little before the target time. This protects against the possibility of losing the connection before the exit order is sent. Also, since it's Bar Closing, I think it will execute at the end of the bar. If you set to 21:00 GMT when markets close, with 5 minute data, I think it will send it at the end of the bar which is 21:04. This runs a high risk of not exiting because the market is closed. To better ensure getting out before the weekend, I'd recommend a large margin, ex,
From Hour:  20   From min: 30   (eg, 20:30)
Until Hour:  21    Until min: 00   (eg, 21:00)
this gives 30 minutes, or 6 5-minute bars, for the exit to happen, and will probably avoid the end of the bar noted above.

But the surest method is use this indicator only for research, and be sure to monitor it on Friday afternoon and close manually.

Re: How to force positions closed at 21:00 GMT and/or week close?

krog wrote:

But the surest method is use this indicator only for research, and be sure to monitor it on Friday afternoon and close manually.

I use Day of Week Exit live to close all positions on Friday but it has to be used in conjunction with Day Closing 2 to specify the closing time.

Re: How to force positions closed at 21:00 GMT and/or week close?

Exit Interval indicator:
http://forexsb.com/forum/post/12768/#p12768

Re: How to force positions closed at 21:00 GMT and/or week close?

Thanks for the thorough explanation Krog. I probably would have figured that out eventually, but I was so excited I just slapped it on there in a hurry!  Here is a corrected screenshot showing the settings I'm using now with good success -- THANKS!!

Post's attachments

day-of-week-exit.png
day-of-week-exit.png 3.47 kb, file has never been downloaded. 

You don't have the permssions to download the attachments of this post.

Re: How to force positions closed at 21:00 GMT and/or week close?

SpiderMan wrote:

I use Day of Week Exit live to close all positions on Friday but it has to be used in conjunction with Day Closing 2 to specify the closing time.

Hey Spidey, I meant to ask you... you mentioned "Day Closing 2" once before -- what did you mean by this?  I haven't done anything special with Day-of-Week-Exit (settings screenshot above) and it works just like I expected -- it allows other closing conditions to be added by Generator, but all positions are forcibly closed Friday before GMT 21 (OR logic).

I wanted to understand better what you meant, or how you are using this indicator, to see if its something I would want to try. Thanks

Re: How to force positions closed at 21:00 GMT and/or week close?

I use 30 min charts so Day of week exit will try to close the position just a few seconds before the close for the weekend at (23:59:59 with my broker). This is too late to get the order into the market so you have to use Day Closing 2 to force the close order a little earlier.

Re: How to force positions closed at 21:00 GMT and/or week close?

I wanted to report back that my settings were still not quite right (screenshot from couple posts back). I think I finally have this figured out now, and I'm posting the latest settings screenshot in case anyone else is trying to learn how to do this.

Taking krog's advice, I've set this to close the position several bars before the actual market close. This is the setting I now use when trading M1 timeframe, and I want it to close no later than 20:55 Friday afternoon (3:55pm ET, New York close).

Post's attachments

day-of-week-exit.png
day-of-week-exit.png 2.46 kb, file has never been downloaded. 

You don't have the permssions to download the attachments of this post.

Re: How to force positions closed at 21:00 GMT and/or week close?

pomelov-yuriy wrote:

http://s14.postimage.org/7viy2k531/000qsp1h.jpg

Does she force position closing? big_smile

Re: How to force positions closed at 21:00 GMT and/or week close?

footon wrote:
pomelov-yuriy wrote:

http://s14.postimage.org/7viy2k531/000qsp1h.jpg

Does she force position closing? big_smile

How do you code that indicator??

Re: How to force positions closed at 21:00 GMT and/or week close?

I think, there is no Day of the week exit indicator anymore, isn't it?
I cannot find it in FSB...

16 (edited by Popov 2012-04-07 21:09:11)

Re: How to force positions closed at 21:00 GMT and/or week close?

I think, there is no Day of the week exit indicator anymore, isn't it?

Hmmm !! I don't remember why, but Day of Week indicator is available as Opening Logic Condition only.
Was it available as exit condition before?

EDIT:

There is a Day of Week Exit indicator from Krog: http://forexsb.com/forum/topic/2228/day-of-week-exit/