prejudice are starting out and wanted to know how and the code for a smallindicator that should make the difference between 2 moving averages
- Indicators: Schaff Trend Cycle
- sma fast - slow sma
- sidus indicator
they are not slaves .... I'm trying to learn but because they are not very good at English as you do more difficult and Ineed some simple examples like this !!!!!!!!!!
I do not think for you is so hard to make an indicator that the subtraction between two moving averages!
If you don't want a slave to code it for you.
If you are trying to learn.
POST YOUR CODE.
Many examples in the code base.
Wouldn't be hard at all, but every day some lazy person, unwilling to put any effort into learning asks for someone to code it for them for free. No SLAVES here.
//+------------------------------------------------------------------+ //| PROVA.mq4 | //| Copyright © 2010, MetaQuotes Software Corp. | //| http://www.metaquotes.net | //+------------------------------------------------------------------+ #property copyright "Copyright © 2010, MetaQuotes Software Corp." #property link "http://www.metaquotes.net" #property indicator_separate_window #property indicator_color1 DarkOrchid //---- input parameters extern int MAShort= 22; extern int MALong= 90; //+------------------------------------------------------------------+ //| Custom indicator initialization function | //+------------------------------------------------------------------+ double start() { double A; double B; double C; double i; A= iMA( NULL, 0,MAShort, 0, MODE_SMA, PRICE_CLOSE, i); B= iMA( NULL, 0,MALong, 0, MODE_SMA, PRICE_CLOSE, i); C= A-B; return(0); }WHY THIS INDICATOR NOT FOUND??
alend:
WHY THIS INDICATOR NOT FOUND??
It's not really an Indicator . . . it keeps overwriting the difference between the 2 MAs for the current bar to variable C. And that is all it does . . . it doesn't output the value to a line on screen, it doesn't store it to a buffer that could be accessed by iCustom . . it, in real terms, is useless.
WHY THIS INDICATOR NOT FOUND??
You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register