A custom MetaTrader 5 indicator, built from your own rules
Most indicator ideas start as "show me when…". To turn that sentence into a program, a few things it leaves open have to be decided. Here are the five that matter, with an example at the end.
1. What does it draw?
- Lines, on the price chart or in their own window below it — averages, bands, a smoothed oscillator.
- A histogram — a value above or below zero.
- Arrows or dots on the candles where a condition is true.
- Zones — a range, a trading session, an area between two prices.
- A small panel with text or numbers in a corner of the chart.
Lines, histograms and arrows live in indicator buffers, which another program can read; zones and panels are chart objects. It matters if one day you want a trading system to read your indicator.
2. On which candle?
"When the price crosses the average" can mean the moment it touches, while the candle is still forming, or once a candle has closed on the other side. A rule decided on a closed candle never changes afterwards. A rule decided on the live candle can appear and disappear several times before that candle ends.
3. May it repaint?
An indicator repaints when marks on candles that have already closed move or vanish later. It makes the past look better than it was: an arrow that only appears after the move is easy to trade in hindsight. Unless you ask otherwise, uBotDesign builds indicators that do not repaint closed candles. Some tools, such as swing points that are only known after the fact, cannot be drawn any other way; if you want one, say so and the summary will say it repaints.
4. Another timeframe or symbol?
An indicator can read a higher timeframe — the daily range drawn on a smaller chart, for example — or another symbol. A higher-timeframe value is only final when that candle closes, so decide which you want: the final value, which arrives later, or the running one, which can still change.
5. Should it alert?
A pop-up, a sound, a push notification to your phone or an e-mail. Alerts are built only if you ask for them, with an input to switch them off, and at most once per closed candle — one event, one alert.
Putting it together
Draw an up arrow under a candle when it closes above the upper band after three closes inside the bands, and a down arrow above a candle in the mirror case. Closed candles only. Alert once when an arrow appears.
Every number in it — the band settings, the three candles — becomes an input you set yourself in the terminal, so you never have to decide them up front.
How uBotDesign builds it
Describe the indicator in the chat, in any language. The assistant asks only whether you want a feature, never for a number. You get a written summary of what it draws and when; the factory writes the indicator, compiles it, runs it over past prices to check what it drew, and puts the file on your shelf, ready for the Indicators folder of MetaTrader 5.
Talking to the assistant costs nothing. A build's price is shown before you confirm.