Site Network: Home | Forex-TSD | Forex Factory | Kaskus

Showing posts with label Expert Advisor. Show all posts
Showing posts with label Expert Advisor. Show all posts

Based at Cin Loi's question about how does Isakas EA work, I will try to explain in this post because I think it is a bit longer and should be read by everyone who wants to test this EA.

Isakas EA is made based on Isakas II strategy at Forex-tsd.com. Here is the link. This strategy basically uses 4 indicators (BBStop, NonLagDot, FisherKuskus, and FlatTrend) but then modified just using 3 of them without FlatTrend.

Main Rules for Isakas II Strategy (taken from the post at Forex-tsd.com)
Entry Buy
- bbands blue, fisher blue, nonlagdot blue.
Entry Sell
- bbands red, fisher red, nonlagdot red.


My EA doesn't open new position just like the picture above because some people said it is not profitable (read the full thread and you will find about it, pheew... it is a long thread). There is a rule about the valid signal because mostly the signals are not happened in the same candle. So, there is an added parameter for counting the signal at the EA's parameter. This should be handled by "SignalBarCounter" in the EA.
For an example SignalBarCounter=3, when BBStop turn color into Blue (buy signal) but NonLagDot is still red then EA should wait for the next 3 candles until NonLagDot changes into blue. But when this condition isn't met then EA will ignore this signal and wait until BBStop turns into different color.

EA Isakas


As a part of my open project, this expert advisor is written from famous strategy based from Isakas thread at forex-tsd.com . Actually, this strategy was not the winner from my poll because the one that suggest it, Marcel, asked me to withdraw it. But the result from poll was different, this Isakas strategy was the one that most chosen by audience. So here it is the Isakas EA. I named it as ISAKAS TW (TW is Tiger_Wong, my favorite nickname) for making different with the Isakas EA that is published at forex-tsd.

EA_Name = "ISAKAS TW";
MagicNumber = 2008;
Lots = 0.1;
Slippage = 3;
TakeProfit = 200;
StopLoss = 0;
UseTrailingStop = true; //set true if want to use trailing stop
TrailingStop = 50; //only active if "UseTrailingStop" = true
AutoTakeprofit = true; //set true to take profit when signal changes
AutoBreakEven = true; //set true if want to use break even function
BreakEvenPips = 50; //only active if "AutoBreakEven" = true
ModeScalp = "Set True to activate";
UseForcedTP = false; //set true if TakeProfit value is tight
ForcedTP = 5; //only active if "UseForceTP" = true
MarginCutOff = 1000; //EA will close all positions if margin below this value
SignalBarCounter = 3; //Value to determine valid signal for how many previous candle that the signal was happened from all indicators
Shift = 1; //set = "0" to use running candle to confirm the signal from indicators
UseTick = false; //set = "true" to allow EA to open a new position in the same candle

I share 2 version of ISAKAS TW. One is using FlatTrend and the other is not. This because I read some comments from the original thread that FlatTrend indicators seems is useless. But both of them seems not profitable... or maybe I haven't found the right setting yet. So, please share your setting if you find the right one ;)

Download EA Isakas here
Download backtest statement here

update 7/21/08 :
For people who have difficulties about download from bizhat, please use the link below.
Download EA Isakas here
Download backtest statement here


After 2 months from the Project started, now we already had a winner for the open project EA. As we can see at the left picture, Kuasa Forex Strategy is the most popular choice but unfortunately it was cancelled due to request from Marcell, the one who brought it into poll. So, I have to stay on the track for eliminating Kuasa Forex and choose GBP/USD Daily as the winner.

But don't be worry for people who loves Kuasa Forex since I already have a plan to write it into an EA, too. We must wait for a few days (or week) before that happens because my routine. Just for our secret, I already write an EA which is very similar with Kuasa Forex. If you have already read my previous post about Simplicity Strategy, you will understand what I mean ;)

Ok, now back into GBP/USD Daily Strategy as the winner of the poll. The good news is the EA is ready. I already made 2 version of this EA due to different result from backtest. The difference is v1 ignores Doji Candle for closing position but v1.1 use that as requested from the original thread. For detail, please go to the http://forex-strategies-revealed.com/advanced/midnight-setup

Now, let's check the result from very short period of backtest from these 2 version of GBP/USD Daily EA. I named this EA as "Midnight EA".

Backtest of v1













Backtest of v1.1






From the short period of backtest result, it seems version 1 (without Doji rule) is more profitable than v1.1. But I don't know for longer period since I haven't done that. For that purpose, I ask people who download and do backtest for longer period to share the result here. I will very appreciate it.

EA's Parameter
MagicNumber = 2008; //identifier for using the same EA at different pair
Lots = 0.01; //starting lot
OrderStopPips = 5; //Distance in Pips for placing stop order
StopLossPips = 3; //Distance in Pips for placing stop loss
MinPrevRange = 90; //Minimal Daily Range Rules
TakeProfit = 50; //TakeProfit
DojiRange = 10; //Value for defining Doji Candle (Absolute value of OPEN - CLOSE)
Slippage = 5; //Slippage

Download link for the detail statement of backtest from v1 is here
Download link for the detail statement of backtest from v1.1 is here
Download link for the EA Midnight v1 is here
Download link for the EA Midnight v1.1 is here

PS: Please don't ask for the source code because I won't share it. It took a lot of time to write an EA but some people will claim it and sell it.

I wrote this EA based at an EA that was published at a forum (I forgot the name). At there, the creator shared the EA for demo only. After I learn it from the backtest result, I tried to make the clone. Basically, this EA is using martingale system. The difference is the code for trigger function.

This EA is one of my portfolio, but I have not write the source code from the scratch. I have modified the source code from Terminator EA, one of martingale family EA, originally made by Alejandro Galindo. After I made some experiments with it, I found an interesting system which may reduce the total risk of floating minus that can made Margin Call.

I try to make comparison between the original and the modified. From my opinion, the fear from martingale system is floating loss. Let's see my result first.

A. Original Version
Backtest result :


B. Modified Version
Backtest Result:



Both version gives different total profit and Biggest Floating Minus. The original version gives more profit but the unseen risk is bigger since its floating minus is about -$9599. The modified version is less profit and smaller risk since its floating minus is about -$2409.

I will share the EA but for return, I will ask you to join at fxopen micro account or liteforex under my referral link. The EA will only run at one account and one broker. So, send me an email if you like to use EA (please mention what version do you prefer).

For reference, I suggest to start this EA using micro account and the starting balance for fxopen micro account is $100 (worth as $100,000 at fxopen micro account, starting lot 0.1) or $100 (worth as $10,000, starting lot 0.01)


I got an email from someone who asked for a time filter for FXTradePro - Clone. I think it is a good parameter to enhanced this EA. So, I put a code for filtering the trading time so people can try as much as they want for different strategy with FXTrade Pro trading system.

Don't forget to change the magic number everytime you attach the EA to the chart. The number must be different from all numbers that may have used before because this EA read all histories from you account history pool.

Setting:
UseTimeFilter = true; //on/off TimeFilter parameter
UseHourTrade1 = true; //on/of for Hour Trade 1
FromHour1 = "0:00"; //start time for 1st Trading
UntilHour1 = "23:59"; //end time for 1st Trading
UseHourTrade2 = false; //on/off for Hour Trade 2
FromHour2 = "0:00"; //start time for 2nd Trading
UntilHour2 = "23:59"; //end time for 2nd Trading

EA can be download at here

rev. 09/02/2008 : fixed bug from huge journal file (see picture below)

I got some input from friends who use this FXTradePro EA from my previous post about huge log file that was appeared after they used this EA in live trading. After check it, I found a function that may cause the problem. Now I upload the new file that is already fixed from that bug.

Thanks for everybody who gives input. Hope you will get more profits with this EA!

Link to download the EA : here

update 5/10/2008 :
For people who has trouble for download at the link above,
please try download at rapidshare : here

For a relative long period, I have wrote several EA’s and try to backtest them in purpose to find wheter they are profitable. Some coder gurus have posted about procedure to get better backtest qualities. From getting tick data from Alpari’s website until disconnected MT4 platform have already done by me. I already got 90% backtest quality using Alpari’s tick data. The sad news is, almost (let say all) my EA were failed in backtest.

So, I was already desperate to find a good EA until a few days ago when my friend, Duyduy, did a backtest for a commercial EA that has already proven profitable in live trading. It is weird that EA was failed, too in backtest. That EA was already backtested by the author but with tick data from metaquotes.net. His backtest was good and the live trades was same.

I am thinking wheter our procedure to backtest an EA using tick data from Alpari’s is invalid. If that is true, imagine how many free EA’s that was never tested in live because they were failed in backtest procedure. Until this day, I have not been able to make a conclusion about this because backtest algorithm is far away from me. I want to open discussion about this problem with anyone who is interested in this theme, especially some mql4 coders. If any of you understand further about this backtest procedure, don’t hestitate to give a comment in this post. I will really appreciate that.

Have you ever read FXTrade Pro's trading strategy at ForexFactory.com? His strategy uses semi martingale lots which is good if you know how to use it. Why we call it semi martingale? Because calculation of the next lots is different from original martingale. In original version, we are doubling the next lots from the previous one. But in FXTrade Pro's strategy, we are not doing the same thing but are still growing the next lots based at our calculations.

Here is the progression of the next lots :


So, what is the main strategy? His strategy uses TakeProfit = 40 and StopLoss = 10 in every sequence with the progression lots. For example, we buy 0.1 lots Eur/Usd at 1.3500 with TP=40 pips and SL=10 pips. This is first sequence. Then our SL is hit. We open the next sequence which is sell 0.1 lots Eur/Usd at 1.3490 with same TP and SL. If our SL is hit once again, we open the next sequence. For better explanation, you can check the picture below.


This simple strategy is very useful if we can combine with other strategy such as break out eagle. We can use our own progression lots depend on our risk ratio and equity. For this purpose, please find the lots calculator in xls format at the link below.

Hint : Use this strategy at brokers company which give you ability to put thin Stop Loss and high leverage margin. (Remember, not all brokers permit us to put SL for 10 pips)

For this strategy, FXTrade Pro already developed an Expert Advisor but it is not free. That's the reason why he was banned from Forex Factory's Forum. Fortunately for my blog's reader, I develop an EA based at his strategy, too. Actually, I develop this EA based at my friend's request, Mr. Duyduy. You can have it for free but use it at your own risk. Please try this strategy and EA at demo first before attach it at live trading.

Remember, this EA is semi automatic. There are two ways to use it.
  1. You can use it as soon as you activate / attach the EA to the chart
  2. Or you can input the price which you want the EA to start trading.
Please find this parameter at the EA's properties.

Don't forget to visit my blog in other time because I still have some interesting Expert Advisor for you all. Thanks for reading my words.

Download the calculator to count the progression lots : here

Download the Expert Advisor for free : here

For forex traders who want to use a strategy based on Moving Average Indicator, I attach an Expert Advisor that can be set for this purpose. Basically, this Expert Advisor could be used for crossing from 2 different period and type of Moving Average but there is an option for 3 MA, too.

These are the setting parameter :

StopLoss (default 100) : Set your Stop Loss. Use 0 (zero) if you don't like to use Stop Loss ( not recommended ).
TakeProfit (default 200) :
Set your Take Profit. Use 0 (zero) if you like to use open target.

TrailingStopType (default 1)
: Set trailing stop type. 1:will start trailing if profit in pips is greater / same with TrailingStop. 2:will start trailing as soon as trade in profit.
TrailingStop (default 40) :
Set the Trailing Stop. Use 0 (zero) if you don't use trailing stop feature.

Moving Average Setting :
------------------------
FastMAPeriod (default 10) : Fast Moving Average Period.
FastMAType (default EMA / 1) : Fast Moving Average Type 0:SMA 1:EMA 2:SMMA 3:LWMA
FastMAPrice (default Close / 0) : Fast Moving Average Applied Price 0:Close 1:Open 2:High 3:Low 4:Median 5:Typical 6:Weighted
FastMAshift (default 0) : Fast Moving Average Shift
SlowMAPeriod (default 80) : Slow Moving Average Period.
SlowMAType (default EMA / 1) : Slow Moving Average Type 0:SMA 1:EMA 2:SMMA 3:LWMA
SlowMAPrice (default Close / 0) : Slow Moving Average Applied Price 0:Close 1:Open 2:High 3:Low 4:Median 5:Typical 6:Weighted
FastMAshift (default 0) : Slow Moving Average Shift

Minimum Cross Distance :
------------------------
MinCrossDistance (default 0) : Set the pip distance between FastMA and SlowMA to be consider as a valid cross. Use 0 (zero) to disable this filter.
MaxLookUp (default 1) : Set number of bar after the cross to keep checking on the entry condition in regards with the minimum distance between FastMA and SlowMA. Need MinCrosDistance > 0 to enable this feature. Use 0 (zero) to disable this feature.

Exit Setting :
-------------
StopAndReverse (default true) : If set to TRUE, will exit any trade and reverse position when signal change.
PureSAR (default false) : If set to TRUE, will use no Stop Loss - Take Profit - and Trailing Stop. This is always in play setting.
ExitOnCross (default false) : If set to TRUE, will exit any trade if there is an opposite cross without consider any additional filter. So exit purely base on moving average cross.

Third MA Setting :
------------------
UseThirdMA (default false) : If set to TRUE (and UseCounterTrend = FALSE), will only trade according to ThirdMA direction, above for BUY and below for SELL.
UseCounterTrend (default false) : If set to TRUE will keep trade even if counter ThirdMA direction, but with different StopLoss and TakeProfit. Need UseThirdMA = TRUE to enable this feature.
OnlyCounterTrend (default false) : If set to TRUE will set the EA only to trade counter trend trade, mean BUY if cross below ThirdMA and SELL if cross above ThirdMA. Need UseCounterTrend = TRUE to enable this feature.
ThirdMAPeriod (defaul 100) : Third Moving Average Period.
ThirdMAType (default EMA / 1) : Third Moving Average Type 0:SMA 1:EMA 2:SMMA 3:LWMA
ThirdMAPrice (default Close / 0) : Third Moving Average Applied Price 0:Close 1:Open 2:High 3:Low 4:Median 5:Typical 6:Weighted
ThridMAshift (default 0) : Third Moving Average Shift
CTStopLoss (default 0) : Set your Stop Loss for CounterTrend trade. Use 0 (zero) if you don't like to use Stop Loss ( not recommended ).
CTTakeProfit (default 0) : Set your Take Profit for CounterTrend trade. Use 0 (zero) if you like to use open target.

Pivot Filter Setting :
-------------------
Use.Pivot.Filter (default false) : Set to true if you like to filter the trade, only BUY if the cross of Slow and Fast MA occur between S1 and S2 and only SELL if the cross of Slow and Fast MA occur between R1 and R2.

Order Setting :
--------------
ReverseCondition (default false) : Set TRUE to reverse the entry condition.
ConfirmedOnEntry (default true) : If set to TRUE, will enter/exit trade on the next bar after the cross confirmed. If set to FALSE, will enter/exit trade as soon as there is a cross.
OneEntryPerBar (default true) : If set to TRUE, will only trade once on one bar. If set to FALSE, will trade more than once on one bar if the entry condition is still valid, although still one trade at a time.
NumberOfTries (default 5) : Number of try if the order rejected by the system.
Slippage (default 5) : Slippage setting.
MagicNumber (default 1234) : Use to generate Magic Number. Change this number ONLY

Multiple Open Trade Setting :
-----------------------------
MaxOpenTrade (default 2) : Number of maximum open trade at one time. This setting is use when StopAndReverse / PureSAR = FALSE so the EA won't close the open order when there is an opposite signal, but rather it will open a new trade. Set the number of open trade allowed. If StopAndReverse / PureSAR = TRUE this setting will always = 1, mean one trade at a time.
MinPriceDistance (default 5) : If multiple open trade enable (by set MaxOpenOrder>1 and OneEntryPerBar=FALSE) this number will determine the minimum distance between each trade on same direction.

Time Filter Setting :
-------------------
UseHourTrade (default false) : If set to TRUE, the EA only active on certain time.
StartHour (default 10) : Time when the EA start active (use with UseHourTrade = TRUE).
EndHour (default 11) : Time when the EA stop active (use with UseHourTrade = TRUE).

Lot and Money Management Setting :
------------------------------------
Lots (default 1) : Number of lot per trade.
MM (default false) : If set to TRUE, will use build in money management.
AccountIsMicro (default false) : If using Micro Account set this to TRUE.
Risk (default 10) : Use with MM = TRUE to set the risk per trade.

Cross Alert Setting :
--------------------
EnableAlert (default true) : Will sound an alert when there is a moving average cross, cross UP or cross DOWN.
SoundFilename (default "alert.wav") : The filename for the alert.

BackTest Setting :
------------------
PrintControl (default true) : Print some comment on backtesting.
Show_Settings (default true) : Show setting on the chart. if you like to run the EA on same pair and same time frame but with different setting.



This EA is created by Firedave at Forex-TSD.com. The credit is for him because his generous for giving this EA freely to all people.

Download Link : here



This EA works based at hedging strategy from two different pairs. As we know, USD/CHF pairs often runs in the opposite direction with EUR/USD. Let say USD/CHF goes bullish then EUR/USD will go bearish mostly. So this EA will open two same positions, mostly buy EUR/USD and USD/CHF in the same time. How we get profit from both positions? Usually we don’t realize that both pairs are not running with same power and same speed. Just for example when one pair is going 10 pips, the other is still going 8 pips. So, when the total profit of both positions is bigger than certain number, EA will close both positions. That’s how the EA works.

For selecting the best time to open positions, we can use the additional indicator called “correlation_v1”. This indicator measures the correlation between both pairs and when they are both in same correlation (one up and others down), EA will open positions.

Actually, I code this EA based at a commercial one that is sold as $95 or RM 350. You may check at original website http://turtle-rock.blogspot.com .

This is my first portofolio that I decide to give free. But I won’t share the source code, still you can have the compiled version (ex4).

Please use this link to download EA and the indicator in rar file.

Firstly, let me say "Happy New Year 2008" for everybody. Hope this year we will be blessed by God with more pips :D .

My forward test for Goblin has given profit US$ 515.29 (about 5% from initial equity) with $53 floating loss. Not bad for 2 weeks.

It was through twice trend change when EUR/USD was going up from 1.43xx to 1.47xx and then went down from 1.47xx to 1.45xx. Even EA didn't running in Eur/Usd pair, I think it is a good chance to test since EA worked at Eur/Chf and Eur/Gbp pairs.

Start from today, I will report my forward test for EA Goblin Bipolar in Eur/Chf, Eur/Gbp, Aud/Usd pairs. This EA based on martingale system which some of trader dislike to use. But in my opinion, martingale is one of good and profitable system if we know how to limit our loss and stick at our money management. Thanks to Bluto, one of the greatest EA coder, for sharing this great EA.

This test start at 21 Dec 2007 which using ODL broker and MetaTrader Platform. Start balance $10,000 and today 28 Dec 2007 has already made profit for $366 and floating loss $40. So far, this EA handles floating loss in right way. I think I will make a decision for using this EA live after test it for 2 months which I want to see whether it is pass the hard day in big trend. I welcome any discussion about this EA.