MQL5 Algo Trading community — forex forum for traders and developers
Question I - dangling pointer, memory leak in MQL4, is it same as C/C++, in terms of definition and their actual behaviors? Question II - citing William's words [ https://www.mql5.com/en/forum/347811 ], does avoid using `new()` will get rid of most if not all memory leaks? From my perspective n his
Hello I want to write a program that will add a certain number of pending orders every time the current price moves by a certain amount (for example, 100 pips or by a certain range, for example, 90 to 110 pips), compared to the last and closest pending order. to do once in the condition). And the
Machine learning in trading: theory, models, practice and algo-trading
(35000 1 2 3 4 5 ... 3499 3500)
Good afternoon, everyone, I know that there are machine learning and statistics enthusiasts on the forum. I propose to discuss in this topic (without holivars), share and enrich our own knowledge bank in this interesting field. For beginners and not only there is a good theoretical resource in
Hy guys, simple question and don't know what its wrong here. Please have a look: if( cond1 && cond2){ return 1;} else if(cond3){ return 0;} Warning: '}' - not all control paths
MetaQuotes has launched new MQL5.community information channels on Facebook, X.com (Twitter), and Telegram. These channels provide daily publications of relevant technical materials from the MQL5.com Articles and CodeBase sections. They are designed to promptly update developers on algorithmic
(Thanks for your time and attentions in advance.) When using optimization function of strategy tester in Meta Trader 5(build 4288) it would prompt Initialization error 5 without any further details.(see Pic 1.) (Pic. 1) When using the task manager of Windows 11 I was not able to allocate the cpu to
Quote: "When selling products on the MetaQuotes Marketplace, the platform allows you to specify a certain number of activations for your product. These activations are tied to a unique installation code that ensures the product only works on the buyer's PC³. Regarding coding these activations into
i have problem msg to confirm my phone i can t receive it why ....please help
How can I attach a file in signal/product description? Where must upload the file and share link for users?
We have updated the MQL5.com Chat to further enhance the user conversation experience. Check out the new service interface and updated functions, such as the revised friending logic. Create groups on financial topics, join existing channels, discuss current issues with fellow traders in group chats
Hello, long time ago, that i used mql5 the last time but why i dont the right value out there? value = iHigh ( _Symbol , PERIOD_CURRENT , iHighest ( _Symbol , PERIOD_CURRENT , MODE_HIGH , 20 , 0 )); it should give me the highest price of the last 20 candles regards amando
I know some brokers who are settings the swaps on some symbols to 0/0. It doesn't make sense to me. Has someone some experience, information or ideas about what that could mean ? Example of some symbols swaps
Hello, I've installed MetaTrader 5 on both Android and Windows. I downloaded a new indicator to my account, and it shows up and works on the Windows system, but not on my Android phone. Is it possible to display this indicator on a mobile phone
I have this code in my EA and I am puzzled by the results. Please can someone tell me where my thinking is wrong as I thought that this should load the current chart prices etc. or if it failed print the error statement and error code. It normally prints the ask price correctly and has never printed...
Hey guys, I have a problem with "telegram undeclared identifier in the attached code. I've tried every way but I haven't been able to resolve it. If anyone knows and can solve it I would really appreciate it. tks Samuel
int Consecutive( int Count) { //--- int BB = 0 ; for ( int i = 1 ; i <= Count; i++) { if ( iClose ( _Symbol , PERIOD_H1 , i) - iOpen ( _Symbol , PERIOD_H1 , i) > 0 ) { BB++; } else { BB--; } } //--- return (BB); } Besides using
Hi! I'm considering to build a portfolio of diversified forex pairs to be traded with an EA, my account currency being USD ( IC markets and Eightcap as brokers) E.g. I'm thinking of EURUSD, GBPUSD as main pairs and AUDCAD, NZDCHF for diversification purposes as an example. Though, wouldn't this
This thread won't be about a question or problem, but rather about the anouncement of the presentation and documentation of an exciting trading concept. I plan to do a series of postings here in order to keep you guys updated. Anybody who has an opinion on the topic, please don't hesitate to comment...
There are so many systems out here based on indicators and it takes so much time to go through all of them to see which one deserves merit,I simply did not feel like adding one more. However most are indicator based and lagging indicators make it difficult to really simplify trading decisions and
Market Condition Evaluation based on standard indicators in Metatrader 5
(2368 1 2 3 4 5 ... 236 237)
I just started this thread as a continuation of the talking made on this topic (we can read it). Or ...to make it shorter: it was some discussion about forecasting/predicting of the next candle or direction of the movement or market condition evaluation. And it was around standard indiocators in
Hello, i need create backtest with MA, MACD and Stochastic indicators on daily historical data BTC/USD. I created custom symbol based from EUR/USD and than I changed them to BTC/USD. AFter that I imported the daily historical data to the current symbol. But if I try to make simple backtest than I
Hi everyone, I need support because I'm noticing a problem with my custom indicator. The indicator provides me with a KPI that updates for each new bar. I based an expert on it who, based on the value of the previous bar compared to the current one, must do or not do operations. I had the doubt that
This is the thread about books related for stocks, forex, financial market and economics. Please make a post about books with possible cover image, short description and official link to buy (amazon for example). Posts without books' presentation, without official link to buy and with refferal links...
Hello everyone, I am running a python code to trade on mt5 IC markets and Fusion Markets. I want to know what should I do, where to run the code to have the least latency, currently running the code in equinix NY, where they both have a server but still its slow. It shows 0.5ms in the bottom right
Renko Ashi Trading System 2 Please read the pdf manual for this system. Good luck everyone. PS: Reuploaded the fixed ma in applied price indicator. Special thanks to FXchaser PS: Reuploaded the fixed macd alert indicator. Special thanks to Puzzlebird PS: Reuploaded a Special Settings Template for...
hi I would like to know if there is a good strategy when forecasting highs and lows (ohlc), any links that can help
Hello, I want to copy the signal but whiles I find it on the MQL5 website, it is not on my list of signals of the MT4 Terminal. There are copiers of that signal so it should be available somehow. Does anybody know how to copy that signal ? May be one of the subscribers ? Regards, Stephan
I have a question. As it possible to make backtesting strategy for the past I am wondering if its possible viceversa. So that you put trades in and take out the strategy? Thanks for ansvers
Trading and training video (from youtube for example) about forex and financial market in general. thread for April 2013 - look at this thread, thread for May 2013 - look at here,for June 2013 is here.July thread 2013 is hereAugust thread 2013 is this oneSeptember thread 2013 is hereOctober thread...
SMC (The Smart Money Concept) is different way of market analyzing. I have a SMC strategy which is similar to the bellow example. All I want to know is can I code this thing into an EA or something else to trade automatically? I'm curious to know what is that technology / coding method. Honestly
Hello all, I have a few questions for anyone with knowledge and/or experience trading futures. Any input would be greatly appreciated. From experience scalping in live market conditions, how does slippage and spread compare to trading CFD in markets such as FX? Is there a notable difference, and
how to know which of the trade/stock has the highest volume/most gain
Dax Index January-March 2017 Forecast: flat within bullish with key resistance at 11,649 W1 price is located above Ichimoku cloud in the bullish area of the chart. The price broke 11,485 level to above on close weekly bar with 11,649 as a nearest bullish target to re-enter. Thus, the weekly price is...
The indices market is extremely slow these days and I'm not seeing many trading opportunities... The VIX is at 12.25 right now, what do you do when VIX is this low? Do you switch to other markets or do you just take a break? Also curious about Forex traders, are you seeing a similar problem
CAC 40 January-March 2017 Forecast: bullish with key resistance at 4924.69 W1 price is located above Ichimoku cloud in the bullish area of the chart. The price broke 4860.85 resistance level to above on close weekly bar with 4924.69 as a nearest bullish target to re-enter. Thus, the weekly price is...
Trading has a few simple rules - do the opposite of Goldman's Thomas Stolper; don't fight the Fed; and buy low, sell high. However, as this series of charts from Nanex shows, it is the latter rule that is the easiest to comprehend and yet - thanks to massive and obvious HFT manipulation - is an...
I would like to build futures trading mql robot (mostly focus on oil but other commodities interesting also). Unfortunately it's problem to gain hist. futures data, what's necessary for backtesting. So, I wish to ask: perhaps somebody knows where to receive ticks expired futures
Hi, I have recently started learning MQL5 language and all the tutorials are only focused on Forex market. I have been trading Futures contracts(manually) with <Deleted>. So, my question is If i keep learning Mql5 language, will I be able to develop EA for Futures market(with <Deleted>)? Thank you
Inspired by comments and reviews received from MQL5.community members, we have added a new forum section called "Trading stocks, futures, options and other exchange instruments". Share your ideas and trading experience with the website visitors. Reach out to MetaTrader 5 developers if you have...
Forum on trading, automated trading systems and testing trading strategies Press review Sergey Golubev, 2016.12.24 17:18 Nikkei Q1 2017 Fundamental Forecast: Bullish (based on the article) Fundamental Analysis "The Bank of Japan has been buying stocks for over two years now. And in September, the...
On which MT5 platform can I find the S&P 500, Nasdaq, and Dow Jones index? It's not the type of CFD, it's the real S&P 500, Nasdaq, and Dow Jones indices on the exchange
I want to demo Options board on MT5 but cant find ANY one who offers it? Where can i try the MT5 options board? Who is currently demo/ real trading with MT5 options platform? its ridiculous i cant find ANY information on how to actually do it/ who offers it. Its almost as if it doesnt exist/ noone
DJIA January-March 2017 Forecast: long-term bullish; resistance level at 19,987 is the key W1 price is located above Ichimoku cloud in the bullish area of the chart: the price is on testing 19,987 resistance lkevel to above for the primary bullish market condition to be continuing. The price is
S&P 500 January-March 2017 Forecast: long-term bullish ranging within the narrow s/r levels for direction W1 price is located far above Ichimoku cloud in the bullish area of the chart. The price is on ranging within the following narrow support/resistance levels for the bullish trend to be resumed...
I have recently started using MT5 and am a US resident but I am having difficulty finding a broker that supports MT5. Is there a way around this? I have heard some people using Tradingview and pine connector but looking for the best way to setup MT5 with a US broker. If anyone can help it would be
Hello Friends I am stuck with a following if condition!!! if (!(cCPRM15.rangeR2_R1(CPRD01,j,k) || cCPRM15.rangeR1_Top(CPRD01,j,k))) return ( false ); I want to return(true), if either one condition is true, else return(false). I have tried using && operator too, but it is always returning [false]
Hello everyone. I do optimization based on real ticks. When it finishes I try running single tests and compare with results I see in optimization table. They are not the same. What could the problem be
Please help How to copy from one dimension array directly into the second dimension array of multi-dimension array, without using looping ?? Or is it possible to copybuffer from indicator result into the second dimension of multi-dimension array ?? Thank you
greeting to all please i want very simple code when price go up for 5 points place a buy order take profit after 20 points and stop after 15 points when price go down for 5 points place a sell order take profit after 20 points and stop after 15 points without indicator ***
Can you tell me if this is a realistic tester figure? And is this a good or bad result for a year with a deposit of $3,000
Can an EA be able to completely halt trading from all sources ? Signals, other EAs, manual trading, etc. If so, can it resume trading from all the previously halted sources ? Such EA would have complete power over the account so I don't know if it's possible
Hello everyone, I am currently trying to develop a panel that requires aligning text with the right edge of a graphical background layer. I have been using the TextGetSize() function to calculate the width of the text and attempting to position the text by subtracting this width from the right
I’m in need of a really fast broker and vps. Today I’m using mql vps hosting and has about 0.7ms ping. Is there any way to get the ping down even more with no other broker
Hello, does anyone know how does the experation function fo pending orders Works in MQL5? i found there is an Void https://www.mql5.com/en/docs/standardlibrary/expertclasses/expertbaseclasses/cexpertsignal/cexpertsignalexpiration but also you have the constant from the order Send Function...
Hi, I'm using the Strategy Tester to debug an MQL5 EA strategy that inadvertently issues many PositionModify commands - the journal gets full of server messages and its hard to see the wood from the trees. When using the Strategy Tester, is it possible to (temporarily) block server messages - I just
Would anyone know how to incorporate into a breakeven price calculation the swaps of the given positions? I am working on the function below, which calculate the BE price of positions of a given pair in a given direction, but I have not figure out a simple way to add the losses from swaps into that
Hi, I have a EA which has a struct defined in it (because there are variables of its type in the EA mql file) and the struct type is being used to declare a variable in the header file too. // within mql EA file struct LLevel { ..... } // within mqh file LLevel expiredLLevel[]; After i include
Hello mql5 people. I am currently working on the optimization team for a project. I am a hobbyist coder and have coded a couple of my own bots, however for this project, I do not have access to the code. I was back testing without any problems until the version of the bots, licensing expired. As
Hi everyone, do you have any idea why I get this error when backtesting? Best Reguards, ZeroCafeine. int OnInit () { Handle_MACD_D1 = iMACD ( _Symbol , PERIOD_D1 , FastEMA_D1, SlowEMA_D1, SignalSMA_D1, PRICE_CLOSE ); Handle_MACD_H4 = iMACD ( _Symbol , PERIOD_H4 , FastEMA_H4, SlowEMA_H4
Hello 1) I have seen some websites selling top ranked MQL5 EAs for 30USD and I heard from some people they work perfect. 2) I have been told that given mql5 market EA can work during backtest without purchase they can formulate a dummy MT5 where the EA thinks it is in testing mode but it is actually
how do I backtest an indicator, it doesn't work for me
Hi everyone, before you throw the handbook on me and send me away, please, I confirm that I have tried and done all the research possible. Maybe I have a simple misunderstanding in my edited code, but I can't figure it out alone. 1.) i took the ALMA Indicator V2 and all I wanted to do is to add the
Hi Writing my first EA, steep learning curve but managed to get so far with it using various online sources to sort through most issues. Come across a few issues when using the PVT indicator that I can't explain or find the answers to. EA is running ok but results are not correct and what I have
hi. i want to calculate iStdDev on excel, so i tried to compare iStdDev value and my calculated value. at first, simply period=2 and increases 3, 4... SMA is no problem, but LWMA is not equal. (there is a correlation) Maybe EMA and SMMA are different too. so I wondered why. *calculation accuracy is
sisi: Hi,Mr. Guru could you please help me to constantly refresh an ea after each tick movement. I have tried everything, But I just can't make it refresh constantly. What lines of code must I insert to keep an ea and indicator refresh after every tick? Tnx I hope you could attach your EA so...
RSI indicator We are continuing discussion about the indicators. We have the following thread: Parabolic SAR indicator Momentum indicator Stochastic Oscillator Divergence Indicator Now we are talking about RSI. "Technical Analysis from A to Z": Overview The Relative Strength Index ("RSI") is a
Facing difficulty trying to overlay a line plot on top of Color Candles (in the separate window)
(2)
I made a simple candlestick chart in the separate window (DRAW_COLOR_CANDLES). I wanted to make a moving average in the same window, but when the buffers have very different values it causes the candlestick chart to scaled down so much that you can't see it anymore. Is it not possible to do what I'm
Hello, Dear sir or madam, Can someone modify this indicator to work with the current build of MT4? Thank you! Chris
Hi everyone. I am currently using Supertrend on TradingView and a similar indicator in MQL5 with the same formula, but the middle line between the two is different. Can someone help me verify which formula is correct to display the middle line similar to the indicator on TradingView? Thank you
Hello i am coding indicator for mt5 And 1.after i launch it the buffers draws out of their values that i didnt load in code this is the first question 2.when i call time value in oncalcuulate indicator freez dont respod to other duals like onchert events or ontimer..etc 3.when i run this function it
Some indicators with alert/signals with author's comments: - EMA-Crossover_Signal: Enter two Exponential Moving Average periods and it'll tell you when they crossed. - SMA-Crossover_Signal: Enter two Simple Moving Average periods and it'll tell you when they crossed. - SMMA-Crossover_Signal: Enter...
I have a simple indicator that I use a lot in coding and testing, called BarID. Its intent is: for any bar you point to on a chart, to give you both its AsSeries = true and AsSeries = false index values, along with the best I could do to show its date and time, given all that's available are type
Something I have been working some time ago. Multi pair MACD Multi pair CoeffOfLine
On top of it all, the statements were working fine when I was asking just for close price. As soon as I added time, it started throwing up. 1005 double daNowPrce[]; 1006 datetime dtaNowPrce[]; 1007 ResetLastError (); 1008 1009 double dNowPrce = 0 ; 1010 1011 int
I have a signal indicator that should make an arrow on the LL or HH for any timeframe, but it repaints frantically like a rabid racoon on crack cocaine. One idea to stop something repainting is to take the initial signal it found and force it to remain with some boolean logic, another idea would be
Total Active / Closed orders by order type in MT4 : This script will calculate the total active and closed orders based on order types Author: Biswarup Banerjee
Check trading day end is reached : This script will detect an end-of-trading day and notify Author: Biswarup Banerjee
Close biggest winning / losing trade in MT4 : This script will scan all the open trades and then will close the biggest winning/losing trade Author: Biswarup Banerjee
Place Hedge Order of unbalanced positions in MT4 : This script will place hedge trade of unbalanced type in MT4. Author: Biswarup Banerjee
Close or delete orders based on type in MT4 : This script will close all active trades and delete pending orders based on the order type passed on the input. Author: Biswarup Banerjee
Sequentially Close all trades in MT4 : This script will close all active trades sequentially. following the order in which they were opened Author: Biswarup Banerjee
Check out the new article: Algorithmic Trading With MetaTrader 5 And R For Beginners . Embark on a compelling exploration where financial analysis meets algorithmic trading as we unravel the art of seamlessly uniting R and MetaTrader 5. This article is your guide to bridging the realms of analytical
New article Creating Tick Indicators in MQL5 is published:
In this article, we will consider the creation of two indicators: the tick indicator, which plots the tick chart of the price and tick candle indicator, which plot candles with the specified number of ticks. Each of the indicators writes...
Find the current winning / losing streak in MT4 : Find the current winning / losing streak in MT4 based on filters Author: Biswarup Banerjee
RSI with channels : standart RSI with dynamic levels Author: Andrei Khrushchev
CCI with dynamic channels : a very convenient way to filter out unnecessary signals of crossing levels Author: Andrei Khrushchev
Check out the new article: MQL5 Wizard Techniques you should know (Part 11): Number Walls . Number Walls are a variant of Linear Shift Back Registers that prescreen sequences for predictability by checking for convergence. We look at how these ideas could be of use in MQL5. For a few time-series, it
Adaptive SMA : improved version of the standard Simple moving average indicator with a lower delay Author: Andrei Khrushchev
New article How to Subscribe to Trading Signals is published:
"Signals" in MetaTrader 5 trading platform allow traders to connect to any signal issued by providers. Select and subscribe to any trading signals provider to copy all his or her deals on your account.
How to become an investor and...
Discussing the article: "Master MQL5 from beginner to pro (Part I): Getting started with programming"
(28 1 2 3)
Check out the new article: Master MQL5 from beginner to pro (Part I): Getting started with programming . This article is an introduction to a series of articles about programming. It is assumed here that the reader has never dealt with programming before. So, this series starts from the very basics
Hello, when running the code below MT4 prints: 2020.07.28 11:42:00.097 Class EURUSD,M1: 16 bytes of leaked memory 2020.07.28 11:42:00.097 Class EURUSD,M1: 1 object of type test left 2020.07.28 11:42:00.097 Class EURUSD,M1: 1 undeleted objects left #property strict void OnStart (){ test t =
Hello, I have a custom EA that works fine in the live market, but when doing a back test in the strategy tester , it does not open sell orders. There are no errors or warnings; it just doesn't open sell orders. I've checked every possible reason that might be the reason why it does not open sell
Using a Mac First post and I am sorry if this is in the wrong place. My Navigator window and Market Watch have become undocked.....sure it was my fault. Now, I can't get either back docked?? Does anyone know how to fit this? It is a really silly problem to have without any way to get it back
For a long-term investment purposes and with a profit factor of 2. in M1, with 120 operations during one year. EURUSD only. Time from 2am to 9pm (Helsinki time). Yes or no? Thanks a lot
Hi, some good indis found in the internet (4shared) in this topic! First, a smoothed non-repaint version of macd indicator coded by igorad and mladen. Cheer´s
I am developing a kind of grid system on MT4. The lot sizes will be distributed in one area, increasing the lots for every new position. Requirements: 1) The system knows that can open at maximum x positions. ( x = 5 in the example below) 2) The system shall use a multiplier Z to increase the lot
Any questions from newcomers on MQL4 and MQL5, help and discussion on algorithms and codes
(19637 1 2 3 4 5 ... 1963 1964)
In this thread I want to begin to help those who really want to understand and learn programming in the new MQL4 and want to easily switch to MQL5 - the languages are very similar. This blog will be a good place to discuss tasks, algorithms of their solution and any other questions concerning MT
Wondering if anyone has successfully made an EA that runs on the ByBit MT4 platform. I'm having issues using strategy tester with crypto pairs, getting the following errors: Tester: exchange rate cannot be calculated Tester: margin exchange rate cannot be calculated I'm guessing the issue has to do
Hi all, Im wondering if anyone can help, i have attached screenshots for reference however i am using the exact same account with the exact same data feed and have different fractals on my mobile app compared to my desktop app and im using the exact same indicator, can someone explain why this
Hello. Is it possible to create a button that when pressed behave like when you press the "draw rectangle" button but it gives you a rectangle of a certain color? Like create a button called "white" rectangle and when you press it then you can draw a white rectangle with your cursor, without having
Hello everyone, I need a help about coding. Actually, I am learning about coding and decided to make an expert advisor, but along the way I got stuck because it doesn't work well in MT4. I want to make an EA with following specifications: - To Buy or Sell when MA crosses. - When the opened Buy order
I have download the a new MT4 app from a new broker. but unable to log in to the MQL5 community. I used forum log in and reset password few time but nothing worked Any help or suggestion is welcome. Thanks
Is there any way to automate the process of strategy testing. l want to run multiple tests for various assets with different parameters of each and save the reports. Is there any native or third party api to write code and execute the tests automatically or can l write a script to do the whole...
I just purchased an EA and when I try to download it to the terminal and login, I get this message. Any help would be appreciated. Thanks
ObjectCreate ( 0 , "Low" , OBJ_TREND , 0 , iTime ( NULL , PERIOD_MN1 , 3 ),lowY, TimeCurrent (),lowY); ObjectSetInteger ( 0 , " Low" , OBJPROP_RAY , true ); ObjectSetInteger ( 0 , " Low" , OBJPROP_COLOR , clrRed ); ObjectSetInteger ( 0 , " Low" , OBJPROP_STYLE , STYLE_SOLID ;
![MQL5 - Language of trade strategies built-in the MetaTrader 5 client terminal](https://c.mql5.com/i/registerlandings/logo-2.png)
You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
If you do not have an account, please register
Allow the use of cookies to log in to the MQL5.com website.
Please enable the necessary setting in your browser, otherwise you will not be able to log in.