MQL4 - automated forex trading   /  

Code Base

Read Financial Magazines in MetaTrader 4 and MetaTrader 5!

Code Base  Expert Advisors  Daily Opening EA (needs improvement ideas!) To post a new code, please log in or register

Download MetaTrader 5 and visit MQL5.community Code Base
and Trade on the Go!
and Trade on the Go!
Couldn't find the right code? Order it in the Jobs section

This Expert Advisor is for
MetaTrader 4
Download MT 4 - 455 Kb

and Trade on the Go!

and Trade on the Go!

Name:
Daily Opening EA (needs improvement ideas!)
Author: ubuntuboy (2010.07.12 10:56)
Downloaded: 1665
Download:
 daily_op_res.zip (129.3 Kb)
 Daily Opening EA v2.mq4 (2.9 Kb) View

Obviously looking for ideas to improve! Open to comments and code changes.

Message me or reply with your ideas/comments.

I'll implement them as fast as possible and get back to you with the results.

The Idea:

Using an assortment of indicators, we try to predict the general direction of the next day. In the current version, the indicators are CCI(50), RSI(21), and MACD(default). If it thinks the day will be bearish, it puts up a sell pending only; same with buy pending. It also uses adjustable lot sizes. You can specify what fraction of your current equity you want to risk, then it will calculate the appropriate lot size (max 10 for now) based on your allowable risk. For example, RiskPercentage = 0.01 = 1%. That means if you lose a trade, it will be about 1% of your previous equity. Well, that's the idea anyways. Who knows if it actually works properly. Also note: STOPLOSS AND TAKEPROFIT VARIABLES ARE BOTH IN POINTS - ADJUST PER BROKER. THE EA WAS WRITTEN FOR A 5 DIGIT BROKER.

Disclaimer: this EA was developed by studying the many EAs already on this site, a good number of them using this same strategy. I don't take credit for the idea. I just want to help develop it!

Current Results:

Currently, the results aren't profitable. I've attached the reports from backtesting for the most recentish 1.5 years and for all my history data. Neither of these results were optimized. Just using the default values I setup at random.

I think I found some time ago that a 2-5% risk percentage yielded the best results. This is an old EA that I've recently started to develop again so those old results are lost in my subconscious already. Anyways, this might prove interesting to some people - it helps confirm what you hear lots of traders saying about risking only 2% of your current equity.

What We Need To Do:

  • Increase the winning percentage (find better indicators?)
  • Find optimal TP/SL pairings
  • Find optimal pair to trade
  • Clean da codez
1 comment  To post a new comment, please log in or register
Man, you could optimize some old bots here instead.
16.12.2010 18:49 26994