How to Backtest in MT4 - Trading Heroes « Learn Forex ...

Any Luck with Ninjascript?

Hey guys, A little about me - I've been writing algos on and off for about a year and a half now. I started with Quantopian way back using python to write stock algos, then realised I couldn't live trade with it, so that put me off that.
I then found MT4 and MetaEditor and the world of forex... I was immediately in love with the simplicity of the language (C#), but I ditched it because forex just felt impossible to code around with all the volatility and news based price action. (I'm sure there's exceptions to this - but does anyone have a similar experience with it?)
I finally landed on NinjaTrader and scalping futures, which is amazing and seems to fit way better.
I'm wondering if anyone has experiences with successful Ninjascript trading systems and what advice they have etc. I've written up a few, one with a 76% success rate over 50 days but I'm starting to see how commission and tax really can have an impact...I'd also like to know about the reliability of backtesting using the Strategy Analyser vs Market Replay...
Who's out there! :)
submitted by photoshoplad to algotrading [link] [comments]

So you wanna trade Forex? - tips and tricks inside

Let me just sum some stuff up for you newbies out there. Ive been trading for years, last couple of years more seriously and i turned my strategies into algorithms and i am currently up to 18 algorithms thats trading for me 24/7. Ive learned alot, listened to hundreds of podcasts and read tons of books + research papers and heres some tips and tricks for any newbie out there.

  1. Strategy - How to... When people say "you need a trading strategy!!" Its because trading is very hard and emotional. You need to stick to your rules at all times. Dont panic and move your stop loss or target unless your rules tell you to. Now how do you make these rules? Well this is the part that takes alot of time. If your rules are very simple (for example: "Buy if Last candles low was the lowest low of the past 10 candles." Lets make this a rule. You can backtest it manually by looking at a chart and going back in time and check every candle. or you can code it using super simple software like prorealtime, MT4 ++ Alot of software is basicly "click and drag" and press a button and it gives you backtest from 10-20-30 years ago in 5 seconds. This is the absolute easiest way to backtest rules and systems. If your trading "pure price action" with your drawn lines and shit, the only way to truly backtest that kind of trading is going in a random forex pair to a random point in time, could be 1 year ago, 1 month ago, 5 years ago.. and then you just trade! Move chart 1 candle at a time, draw your lines and do some "actual trading" and look at your results after moving forward in the chart. If you do not test your strategy your just going in blind, which could be disaster.. Maybe someone told u "this is the correct way to trade" or "this strategy is 90% sure to win every trade!!!" If you think you can do trading without a strategy, then your most likely going to look back at an empty account and wonder why you moved that stop loss or why you didnt take profit etc.. and then your gonna give up. People on youtube, forums, interwebz are not going to give you/sell you a working strategy thats gonna make you rich. If they had a working strategy, they would not give it away/sell it to you.
  2. Money management - How to.... Gonna keep this one short. Risk a small % of your capital on each trade. Dont risk 10%, dont risk 20%. You are going to see loosing trades, your probably gonna see 5-10 loss in a row!! If your trading a 1000$ account and your risking 100$ on each trade (10%) and you loose 5 in a row, your down -50% and probably you cant even trade cus of margin req. Game over.. Now how does one get super rich, super fast, from risking 1-3% of your account on each trade?? Well heres the shocking message: YOU CANT GET RICH FAST FROM TRADING UNLESS YOUR WILLING TO GO ALL IN! You can of course go all in on each trade and if you get em all right, you might get 1000%, then you go all in 1 more time and loose it all... The whole point of trading is NOT going bust. Not loosing everything, cus if you loose it all its game over and no more trading for you.
  3. Find your own trading style.... Everyone is different. You can have an average holding period of 1 month or you could be looking at a 1 min chart and average holding time = 10 minutes. For some, less volatility helps them sleep at night. For others, more volatility gives them a rush and some people crave this. There is no "correct" timeframes, or holding periods, or how much to profit or how much to loose. We are all individuals with different taste in risk. Some dont like risk, others wanna go all in to get rich over night. The smart approach is somewhere in the middle. If you dont risk anything, your not gonna get anything. If you risk everything, your most likely going to loose everything. When people are talking about trading style, this is kinda what that means.
  4. There are mainly 2 ways to trade: Divergence and Convergence. Or in other words: Mean reversion or trend following. Lets talk about them both: Trend following is trying to find a trend and stay with the trend until its over. Mean reversion is the belief that price is too far away from the average XX of price, and sooner or later, price will have to return to its average/mean (hence the name: MEAN reversion). Trend following systems usually see a lower winrate (30-40% winrate with no money management is not uncommon to see when backtesting trend following systems.. You can add good money management to get the winrate % higher. Why is the % winrate so low? Well a market, whatever that market is, tend to get real choppy and nasty right after a huge trend. So your gonna see alot of choppy fake signals that might kill 5-6 trades in a row, until the next huge trend starts which is going to cover all the losses from the small losses before the trend took off. Then you gotta hold that trade until trade is done. How do you define "when trend starts and stops"? Well thats back to point 1, find a strategy. Try defining rules for an entry and exit and see how it goes when you backtest it. For mean reversion the win % is usually high, like 70-90% winrate, but the average winning trade is alot smaller than the average loosing trade. this happens because you are basicly trying to catch a falling knife, or catch a booming rocket. Usually when trading mean reversion, waiting for price to actually reverse can very often leave you with being "too late", so you kinda have to find "the bottom" or "the top" before it actually has bottomed/ topped out and reversed. How can you do this you ask? Well your never going to hit every top or every bottom, but you can find ways to find "the bottom-ish" or "the top-ish", thens ell as soon as price reverts back to the mean. Sometimes your gonna wish you held on to the trade for longer, but again, back to point 1: Backtest your rules and figure that shit out.

Read these 4 points and try to follow them and you are at least 4 steps closer to being a profitable trader. Some might disagree with me on some points but i think for the majority, people are going to agree that these 4 points are pretty much universal. Most traders have done or are doing these things every day, in every trade.
Here is some GREAT material to read: Kevin Davey has won trading championship multiple times and he has written multiple great books, from beginner to advanced level. Recommend these books 100%, for example: Building winning algorithmic trading systems" will give you alot to work with when it comes to all 4 of the above points. Market wizards, Reminiscences of a stock operator are 2 books that are a great read but wont give you much "trading knowledge" that you can directly use for your trading. Books on "The turtles" are great reading. Then you have podcasts and youtube. I would stay away from youtube as much as possible when it comes to "Heres how to use the rsi!!!" or "this strategy will make you rich!!". Most youtube videoes are made by people who wanna sell you a course or a book. Most of this is just pure bullshit. Youtube can very harmfull and i would honestly advice about going there for "strategy adivce" and such. Podcasts tho are amazing, i highly recommend: Better systems trader, Chat with traders, Top traders unplugged, We study billionairs, to name a few :)
Also, on a less funny note.. Please realize that you are, and i am, real fucking stupid and lazy compared to the actual pro's out there. This is why you should not go "all in" on some blind stupid strategy youve heard about. This is why this is indeed VERY FUCKING HARD and most, if not everyone has busted an account or two before realizing just this. Your dumb.. your not going to be super rich within 1 year.. You can not start with 500$ account and make millions! (some might have been able to do this, but know that for every winner, theres 999 loosers behind him that failed... Might work fine first 5 trades, then 1 fuckup tho and ur gone..
And lastly: Try using a backtesting software. Its often FREE!!! (on a demo account) and often so simple a baby could use it. If your trading lines and such there exists web broweser "games" and softwares that lets you go "1 and 1 candle ahead" in random forex pairs and that lets you trade as if its "real" as it goes.
A big backtesting trap however is backtesting "losely" by just drawing lines and looking at chart going "oh i would have taken this trade FOR SURE!! I would have made so much money!!" however this is not actually backtesting, its cherry picking and its biased beyond the grave, and its going to hurt you. Try going 1 candle at a time doing "real and live" trades and see how it goes.

Bonus point!!
many people misunderstands what indicators like the RSI is telling you. Indeed something is "overbought" or "oversold" but only compared to the last average of xx amounts of bars/candles.
It doesn't tell you that RIGHT NOW is a great time to sell or buy. It only tells you that the math formula that is RSI, gives you a number between 1-100, and when its above 70 its telling you that momentum is up compared to the last average 14 candles. This is not a complete buy/sell signal. Its more like a filter if anything. This is true for MOST indicators. They INDICATE stuff. Dont use them as pure buy/sell signals.. At least backtest that shit first! Your probably gonna be shocked at the shitty results if you "buy wehn rsi is undeer 30 and sell when RSI is above 70".

Editedit: Huge post already, why not copy paste my comment with an example showing the difference in trend following vs mean reversion:
The thing about trend following is that we never know when a trade starts and when it ends. So what often happens is that you have to buy every breakout going up, but not every breakout is a new trend. Lets do an example. Check out the photo i included here: https://imageshost.eu/image/image.RcC

THE PHOTO IS JUST AN EXAMPLE THAT SHOWS WHY A TYPICAL TREND FOLLOWING STRATEGY HAVE A "LOW" WINRATE.
THE PHOTO IS NOT SHOWING AN EXAMPLE OF MY STRATEGIES OR TRADING.

  1. We identify the big orange trend up.
  2. We see the big break down (marked with the vertical red line) this is telling us we are not going higher just yet. Our upwards trend is broken. However we might continue going up in a new trend, but when will that trend come?
  3. We can draw the blue trend very earyly using highs and lows, lines up and down. Then we begin to look for breakouts of the upper blue line. So every time price breaks upper blue line we have to buy (cus how else are we going to "catch the next trend going up?)
As you can see we get 5 false breakouts before the real breakout happens!
Now if you could tell fake breakouts from real breakouts, your gonna be rich hehe. For everyone else: Take every signal you can get, put a "tight" stop loss so in case its a fake signal you only loose a little bit. Then when breakout happens as you can clearly see in chart, your going to make back all the small losses.
So in this example we fail 5 times, but get 1 HUGE new trend going further up. This 1 huge trade, unless we fuck it up and take profits too early or shit like that, is going to win back all those small losses + more.
This is why trend following has a low winrate. You get 5 small loss and 1 big win.

Now lets flip this! Imagine if your trading Mean reversion on all the same red arrows! So every time price hits the blue line, we go short back to the bottom (or middle) again! You would have won 5 trades with small profits, but on that last one you would get stopped out so hard. Meaning 5 small wins, 1 big loss (as some have pointed out in comments, if you where trading mean reverting you would wanna buy the lows as well as short the tops - photo was suppose to show why trend following strategies have a lower % winrate.)

Final edit: sorry this looks like a wall of text on ur phones.
submitted by RipRepRop to Forex [link] [comments]

How to Win in Forex

If you practice strict money management rules, then you will become the casino. The house always wins because the casinos know how to control their losses.
Most people have to learn the hard way.. or don't learn from their losses at all due to emotions getting in the way. Don't be fooled by people who use big lot sizes and make big wins on social media. They suffer big losses too and if they don't control their risk management then they will not last long. The problem is that far too many people want to get rich quickly, but nobody wants to get rich slowly. Some of you, if not most, know what I'm talking about.
Take this scenario for perspective. Let's say we have a contest based on these two constants.
Who is going to come out on top? Undoubtedly, me. Why?
Because at the end of the day, money management is the only thing that will be in charge of making your account go up or down.
So how do you exactly make sure that you are using proper risk management? I would suggest either downloading a position sizing indicator and throwing that on your MT4. This will do all the math for you, saving you countless hours over time. You can find a good one on Google. If you are serious and thinking about becoming a professional forex trader for years to come then you can spend 30 minutes searching for an indicator.
The second part is to stick to your trading system. This will require some backtesting. Save your money and take the time to backtest your system. A system is needed to properly trade forex. Why? Because a system is quantifiable.
A system is basically a series of "if, then" statements.
Example: If price is below my moving average, then do not enter a long position.
You need a string of rules, or constants, to create your system. Again, if you take trading seriously, then you will take all the time you need to play with all sorts of indicators in order to find your own system until you find what works for you. This step is crucial. This is why you can never rely on another person's analysis because it is not consistent and is out of your control.
When it comes to me and my money, I want to eliminate as many things as possible that are out of my control.
With this being said, this should be a clear explanation on why price action trading is nearly impossible to consistently make profits and win in forex. There's way too much guess-work involved. Don't believe me? Have you ever found yourself asking any of these questions below? If you do, then welcome to the majority of traders who lose money.
With this said, ladies and gentlemen.. as much as you want to believe you are some kind of magician, we cannot predict the markets.. especially if you're trading with pure price action.. at least not consistently. Predicting the markets is basically the same thing as trading blindly and it's a sucker's game IMHO.
The purpose of a system is to give you an edge over the markets.
To sum up this lengthy post, here are three takeaways:
  1. Create a quantifiable trading system.
  2. Practice proper risk management.
  3. Find what works for you.
Edit: Things to study.
Baby Pips
Trading in the Zone
No Nonsense Forex
submitted by jarjar- to Forex [link] [comments]

On the development and confidence on your trading systems.

While I've never traded live before and still consider myself a total newbie, I've read plenty of books related to trading and forex in particular and have been demo trading for almost 6 monts both with mt4 and cTrader (and made a couple EAs and algos, since I have a CS background). I've blown more demo accounts than I can remember...
From what I read (and feel free to correct me if I'm wrong) there are only two things you need in order to make it in forex: solid money management and a trading strategy with an edge.
The only thing I couldn't find yet on any book is: How do you develop such a trading strategy?
I don't want to know the secret sauce (when to go long or short), just the reasoning behind those strategies whether they're profitable or not. Is it just trial and error? Let's try to buy EURUSD when price goes above SMA14 on M15... (Backtests over a period of two years. Blows account.) Well, it didn't work. How about trying with H1?... (Back to backtesting...)
Or is it that eventually you develop some kind of intuition about how markets are behaving and some things might work better that others? And just try those until it works? (Purposely leaving aside the discussion about the amount of backtesting you feel comfortable with before going live. I believe that deserves a thread on it's own)
I'd love to hear from both technical and fundamental traders.
UPDATE: A couple of days after posting this question, I came across a series of articles that describe one possible way to approach the development of a trading system:
Build Better Strategies!
Build Better Strategies! Part 2: Model-Based Systems
Build Better Strategies! Part 3: The Development Process
submitted by H3rnst to Forex [link] [comments]

How to backtest? Trying to find optimal TP/SL Price %

So I probably should start with: I wouldn't consider myself the brightest soul on earth. I’ve been plugging away at trading for almost ten years and have basically broken even until this year which has been slightly profitable.
This year I’ve been using a modified “3 ducks” system where instead of 4h1h5min I make sure daily/8h4h3h1hr match. I use Oanda’s software and have the trade defaults setup as: Size = 15% Lev NAV, TP = 0.60% Price, SL = 0.50% Price. It’s not perfect but it’s a starting point to profitability IMO; I am however starting to think the percentages are just a tad too high or I need to try a trailing stop %.
The thing I want to do, but have no idea how to make it happen, is backtest basically every TP and SL combination to find the most profitable setting where I don’t get stopped out too early or take my profits to late. There has to be some sort of optimal percentage to use.
Why do I use the settings? Well, you see, like I said… not that bright of a dude sometimes, so I have a habit of (for lack of a better term) dicking around with my trades. Until I set the software to basically just let me click buy or sell, I’d change too many things like "oh, this one's a winner, let me trade a bigger lot" which resulted in nothing working because inevitably the losses always outweighed the winners.
So I'm pretty sure I need to have these settings in place to keep me from doing stupid stuff, might not make the most profit but hey my living expenses are low. I live in a tiny mountain cabin so if I can make like 40 pips a day I'm happy, I'm going for consistency over trying to become rich.
I know MT4 can do backtests and there’s Forex Trader 3 which basically looks like a modified MT4 install, but how in the world do I test what I want? It seems like I have to code a program but damn, I don't think I could code that sort of thing to save my life.
submitted by missingusernamehere to Forex [link] [comments]

MetaTrader 4 (MT4) - How to use Playback to test your ... How to run back test on MT4 forex platform How to use the Strategy Tester in MT4 for manual Backtesting Backtesting Forex Strategies With My Team - YouTube How to Forex backtest EA or indicator in Your Mt4 Forex platfrom or Tarminal (Tutorial ) Forex Trading: Quick Backtest Tutorial Using MT4 Manual Back testing and Back trading Forex trading ... Back testing in MT4 MT4 Fragen&Antworten: Wie mache ich einen EA Backtest? Professional Simulator Mt4

Backtesting forex strategies is the process of testing a trading strategy on historical data. It will show you how the strategy would have performed in the past using all available tick data. Many traders that use ea’s believe in the theory that if a system performed well in the past it will also do well in the future. Today I will explain in detail how to use the In forex, backtesting is when you apply historical currency pair price data to your strategy to evaluate and gauge the effectiveness of the strategy. The assumption behind backtesting is that what worked in the past can also work well in the future. This means that if a strategy is profitable based on past market conditions, there’s a chance that it will be effective when applied to current ... Automated Trading System Backtesting in MT4 Strategy Tester Report. This is the report and chart generated by the strategy tester by MT4. As you can see, the strategy had an excellent run for a period and then suffered losses. The strategy means everything in the automated trading system. A good strategy can make consistent profits whereas a ... But sometimes when you see trades executing as price moves, the issues become very clear. Therefore, this method of testing is not geared for speed, but it's a way to visually spot issues or optimizations. MT4 Strategy Tester Optimizer. Now that you have a good feel for how the Strategy Tester works, you can start optimizing some of your ... Forex tester 4 is the most complete tool you can find for backtesting Forex trading strategies and suitable for the traders who want to do professional backtesting on a functional well-designed software. It’s not a plug-in or add-on for MT4. Instead, it’s a separate software that looks like MT4 very much but it has some additional features. A standard backtesting on MetaTrader 4 terminal using the data from the MT4 history center is usually good enough for Expert Advisors (EA) that are not scalping or pip hunting. However, if you’re dealing with a scalping EA or any EA that closes trades within 1-15 pips, even the smallest price feed differences might have a very large impact on the results. There are many other backtesters out there like Forex Tester 4 and there are also some interesting addons for MT4 to help with your backtesting. If you are looking for more capabilities with your manual backtesting, FX Blue has a free indicator addon that will allow more advanced capabilities such as; set trailing stops, change s/l and t/p with click of chart and allow quick close of all open ...

[index] [18260] [14537] [8408] [6071] [2615] [9524] [9961] [6807] [9930] [19543]

MetaTrader 4 (MT4) - How to use Playback to test your ...

Antwort auf die Frage: "Wie ist beim Backward-Testing vorzugehen? Wie erfolgt im MT4 das Back-Testing eines Expert Advisors?" Infos zu unserem EA-Programmier... Backtesting Forex Strategies With My Team In this video Jay Wayne will show you how he backtest forex strategies with his team. ..... Spot On Forex - Price Action & Scalping 9,898 views. 6:09. MetaTrader4 - The Complete Guide to MT4 - Duration: 53:11. Russ Horn 302,170 views. 53:11. Day Trading Rules - Secret to Using Fibonacci ... This is a quick video tutorial on how to use the MetaTrader 4 Strategy tester as a manual training tool for learning Price Action. Cómo hacer Backtesting en MT4 - Duration: 14 ... Curso con Simulador para Operar Price Action FOREX go4pips.com - Duration: 1:11:44. Alejandro Arcila 2,714 views. 1:11:44. 3 cosas que no te dicen ... For more information on Forex trading techniques and the Divergence technique shown in the video please use these links:- Forex trading tools http://automate... How to use the Strategy Tester in MT4 for manual Backtesting - Duration: 7 ... WHY YOU NEED TO UNDERSTAND PRICE ACTION WHEN TRADING **FOREX-STOCKS -CRYPTOCURRENCY** - Duration: 20:50. WISE WISDOM ... How To Pay Off Your Mortgage Fast Using Velocity Banking How To Pay Off Your Mortgage In 5-7 Years - Duration: 41:34. Think Wealthy with Mike Adams 860,021 views Hi...This Tutorial i will showing you How to backtest in Forex EA or indicator in Your Mt4 Tarminal 600++. This tutorial you can be used across all Broker an... Try a free demo of MetaTrader here: https://www.icmarkets.com/en/open-trading-account/demo?camp=25329 In this video we will show you how to to playback your ...

https://binary-optiontrade.krugagaban.cf