How can I plot net arrows and support and resistance code?
- Mastering Market Dynamics: Creating a Support and Resistance Strategy Expert Advisor (EA)
- Price Action Analysis Toolkit Development (Part 37): Sentiment Tilt Meter
- News Trading Made Easy (Part 3): Performing Trades
int OnStart() { // ... (previous code - as is) // Check buy and sell conditions for (int i = CountPeriods - 1; i >= 0; i--) { datetime time1 = iTime(NULL, 0, i); // ... (calculate P, R1, R2, R3, S1, S2, S3, H1, H2, H3, H4, L1, L2, L3, L4, and Range as before) datetime time2 = time1 + PeriodSeconds() * 60; // ... (draw lines for DCP, DR1, DR2, DR3, DS1, DS2, DS3, DH1, DH2, DH3, DH4, DL1, DL2, DL3, DL4 as before) double closePrice = iClose(NULL, 0, i); // Buy condition: closing price above pivot level if (closePrice > P && i < CountPeriods - 1) { ObjectCreate(0, "BuyArrow" + IntegerToString(i), OBJ_ARROW, 0, time2, P); ObjectSetInteger(0, "BuyArrow" + IntegerToString(i), OBJPROP_COLOR, clrGreen); ObjectSetInteger(0, "BuyArrow" + IntegerToString(i), OBJPROP_ARROWCODE, SYMBOL_ARROWUP); } // Sell condition: closing price below pivot level if (closePrice < P && i < CountPeriods - 1) { ObjectCreate(0, "SellArrow" + IntegerToString(i), OBJ_ARROW, 0, time2, P); ObjectSetInteger(0, "SellArrow" + IntegerToString(i), OBJPROP_COLOR, clrRed); ObjectSetInteger(0, "SellArrow" + IntegerToString(i), OBJPROP_ARROWCODE, SYMBOL_ARROWDOWN); } } return(INIT_SUCCEEDED); }
Usamos el idioma inglés aquí en el foro, por favor publique su código en inglés. La solución que está buscando son las funciones integradas para su indicador, puede usarlas como plantilla y completar los espacios en blanco a medida que avanza. English: We use english language here in the forum, please post your code in english. The solution you are looking for is the built in functions for your indicator, you can use them as a template and fill in the blanks as you go. Do not use Chat GPT or online generators. The code has many mistakes, it is not hand written