molanis.com/forum - Tools for MetaTrader : The place to ask about the best expert advisor builder, expert advisor downloads, and expert advisor programming
http://www.molanis.com/forum/

Set trading time start / end (not on the hour)
http://www.molanis.com/forum/viewtopic.php?f=6&t=6119
Page 1 of 1

Author:  EddieII [ Sat Feb 07, 2015 8:47 pm ]
Post subject:  Set trading time start / end (not on the hour)

Hi,

I am able to set the trading time to start at '1', which is 10am for the ASX, however, I would like to avoid the first 15min of trading and start t at 10:15am.

It looks like you can only set whole numbers in Molanis.

I can see where the TradingTimeStart can be edited in the code but am unsure of the format, I'm guessing 1:15???

Anyone know?

thanks a bunch!
Eddie

Author:  molanisfx [ Sun Feb 08, 2015 10:53 am ]
Post subject:  Re: Set trading time start / end (not on the hour)

In the start icon you can set the time filters using hours, if you need minutes you can try the TIME icon. You use and AND to join it to your condition.
If you like coding, make an example using the time icon and you will see the format for time and hours

Author:  EddieII [ Mon Feb 16, 2015 3:47 am ]
Post subject:  Re: Set trading time start / end (not on the hour)

Champion - thanks very much! :)

Author:  EddieII [ Sun Mar 01, 2015 6:23 pm ]
Post subject:  Re: Set trading time start / end (not on the hour)

Hi there,

I've tried building this with the Time blocak, adding it as an 'and' condition to the open conditions.

I've tried turning on and off the the 'use trading time' conditions in MT4 but still not able to get it to open at 1:15 and close at 6:59

The molanis file is attached if that helps - any ideas?

Thanks a bunch
Eddie

Attachments:
File comment: Added 'Time' Condition
DAILY_HEDGEv1.2.mol [21.63 KiB]
Downloaded 673 times

Author:  molanisfx [ Mon Mar 02, 2015 12:32 pm ]
Post subject:  Re: Set trading time start / end (not on the hour)

You trade bars so the trading will take place every bar. If you use this ea on a 1 hour chart, it will not trade at 1:15 because the condition is evaluated every hour. You need to put it in a lower timeframe
Also, the open and close conditions overlap so it will close and open again. You need to build a more complex condition for the open

Author:  EddieII [ Tue Mar 03, 2015 4:50 am ]
Post subject:  Re: Set trading time start / end (not on the hour)

Ah, ok, that explains it - thanks very much!

Author:  EddieII [ Sat Mar 07, 2015 1:50 am ]
Post subject:  Re: Set trading time start / end (not on the hour)

Hi there,

I've been playing around with this one and running it on the 5 min chart so have been able to get the open at 1:15 & close at 7 (well 7:05 at least).. thanks.

What I'm trying to do is open at 1:15 & close at 7 with a fixed point stop loss.

Aside from the stop loss, the open and close times are the only entry / exit conditions.

With the time based entry & exit conditions, does anyone know if there a way to build this so that once the stop is triggered, it doesn't open another trade. (I want the entry condition to be a 1:15 open only).

Thanks a bunch!

Author:  admin [ Sun Mar 08, 2015 10:16 pm ]
Post subject:  Re: Set trading time start / end (not on the hour)

The user guide explains a feature called next trade management, the idea behind is that after a position is closed only a position in the opposite direction can be open. It works for tp and sl. Not sure if this meet your needs

Author:  EddieII [ Thu Mar 12, 2015 12:14 am ]
Post subject:  Re: Set trading time start / end (not on the hour)

Thanks, I'll look into this.

Page 1 of 1 All times are UTC - 5 hours
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/