Convertir codigo de de pine (tradingview) a metatrader 5

MQL5 Uzman Danışmanlar

İş tamamlandı

Tamamlanma süresi: 15 gün

İş Gereklilikleri

hola buenos dias necesito convertir el siguiente codigo de pine hecho para tradingview a metatrader5, vigilando que la estrategia funcione exactamente igual que en tradingview


//@version=5

strategy("Estrategia de Scalping Optimizada con Apalancamiento", overlay=true, default_qty_type=strategy.percent_of_equity, default_qty_value=5)

 

// Configuración de indicadores

lengthRSI = input.int(14, "Longitud RSI")

upperThresholdRSI = input.int(70, "Umbral Superior RSI")

lowerThresholdRSI = input.int(30, "Umbral Inferior RSI")

rsi = ta.rsi(close, lengthRSI)

 

// Configuración de Bandas de Bollinger para confirmación

lengthBB = input.int(20, "Longitud BB")

multBB = input.float(2.0, "Multiplicador BB")

basisBB = ta.sma(close, lengthBB)

devBB = multBB * ta.stdev(close, lengthBB)

upperBB = basisBB + devBB

lowerBB = basisBB - devBB

 

// Opción para elegir operaciones en largo, corto o ambos

tradeDirection = input.string("both", "Dirección de Operación", options=["long", "short", "both"])

 

// Opción para apalancamiento

leverage = input.float(1.0, "Apalancamiento", minval=1.0, maxval=100.0, step=0.1)

 

// Señales de entrada más selectivas

longCondition = (rsi < lowerThresholdRSI) and (close < lowerBB)

shortCondition = (rsi > upperThresholdRSI) and (close > upperBB)

 

// Gestión de riesgo dinámica basada en la volatilidad

atr = ta.atr(14)

riskPerTrade = input.float(1.0, "Riesgo por Operación (%)", step=0.1)

stopLossATRMultiple = input.float(2.0, "Múltiplo de ATR para Stop Loss", step=0.5)

 

// Cálculo de tamaño de posición basado en el riesgo, ATR y apalancamiento

riskAmount = strategy.equity * riskPerTrade / 100

positionSize = (riskAmount / (atr * stopLossATRMultiple)) * leverage

 

// Ejecución de órdenes con gestión de riesgo basada en la dirección seleccionada

if (tradeDirection == "long" or tradeDirection == "both") and longCondition

    strategy.entry("Compra", strategy.long, qty=positionSize)

    strategy.exit("StopLoss/TakeProfit Compra", "Compra", stop=close - atr * stopLossATRMultiple, limit=close + atr * stopLossATRMultiple * 2)

 

if (tradeDirection == "short" or tradeDirection == "both") and shortCondition

    strategy.entry("Venta", strategy.short, qty=positionSize)

    strategy.exit("StopLoss/TakeProfit Venta", "Venta", stop=close + atr * stopLossATRMultiple, limit=close - atr * stopLossATRMultiple * 2)

 

// Visualización en gráfico

plot(upperBB, "Banda Superior BB", color=color.red)

plot(basisBB, "Banda Media BB", color=color.blue)

plot(lowerBB, "Banda Inferior BB", color=color.green)

hline(upperThresholdRSI, "Umbral Superior RSI", color=color.red)

hline(lowerThresholdRSI, "Umbral Inferior RSI", color=color.green)


Yanıtlandı

1
Geliştirici 1
Derecelendirme
(158)
Projeler
270
25%
Arabuluculuk
14
29% / 7%
Süresi dolmuş
17
6%
Çalışıyor
2
Geliştirici 2
Derecelendirme
(468)
Projeler
530
33%
Arabuluculuk
28
39% / 43%
Süresi dolmuş
7
1%
Meşgul
3
Geliştirici 3
Derecelendirme
(479)
Projeler
508
53%
Arabuluculuk
10
60% / 20%
Süresi dolmuş
3
1%
Çalışıyor
4
Geliştirici 4
Derecelendirme
(803)
Projeler
1374
72%
Arabuluculuk
113
28% / 48%
Süresi dolmuş
342
25%
Çalışıyor
5
Geliştirici 5
Derecelendirme
(121)
Projeler
158
37%
Arabuluculuk
7
57% / 0%
Süresi dolmuş
28
18%
Serbest
6
Geliştirici 6
Derecelendirme
(563)
Projeler
932
47%
Arabuluculuk
302
59% / 25%
Süresi dolmuş
124
13%
Meşgul
Benzer siparişler
Mi estrategia contiene 4 indicadores y es un solo par, necesito que sea un EA muy estructurado y que se pueda modificar la gestión de riesgo y el horario. la estrategia de maneja en un cierto horario utilizando Ema, g trend, twit Ranger Filter
Bot for ninja 50+ USD
good morning. how can do an indicator in ninja? i have and in dicator in mt4 and i want to become to ninja, I have the bot, i need a person to know to codifing . responsable, good worker , and good comunication
La estrategia se basa en la apertura de Londres en EUR/USD en la temporalidad de 15minutos. Un TP de 15 pips. Un SL de 60pips. el lotaje será calculado según el 10% de la cuenta teniendo en cuenta los 60 pips. Las entradas siempre deben ser En el Horario de las 9:15am según la Zona UTC+1. si la vela de las 9am cierra a la baja se realizara una compra a la apertura de la vela de las 9:15am. En caso de la las ventas la
good morning I want to create a bot with indicator that is in tradingview, the indicador have signal, and I just want to make this indicator in bot. we can see the code, and work with that
Nombre: Serpiente Lote: 0.01 ZigZag true - true/False 1 Depth 100 2 Deviation 40 3 Backstep 25 GRID Niveles grid 3 Distancia lotes 30 SL lotes 0 TP lotes 0 Abrir Largos true/false Abrir Cortos true/false Abrir Ordenes Limite true/false Abrir Ordenes Stops true/false CONDICIONES --Cuando ZZ, sea positivo abrir solo ordenes largas. --Cuando ZZ, sea negativo abrir solo ordenes
Finanzas 30+ USD
La capacidad de él alto monto en negocios varía. Si un producto no mantiene un precio determinado se save que al momento que se vende tiene la suma de mántenerse igual
We are looking for an expert who can create a news EA (expert advisor) who can create a system where users can set their news preferences to low, medium or high. (have an on and off option, so one can choose whether you want to work with news or not) The EA should be able to get news from reliable sources and filter it according to the user's preferences. ( to deliver the source code of the created ea)
i need an EA that operate DAX during first 1800 seconds after the opening of the market 9 AM spanish time. if during the these 1800 first seconds the price reach 1,002*P. (P is the price of the first tick after the opening of the market) there will be a buy entry of 1 contract. if during the these 1800 first seconds the price reach -1,002*P. (P is the price of the first tick after the opening of the market) there
Actualmente estoy usando un asesor experto de MetaTrader 4 para operar, pero he notado que no maneja bien los períodos de noticias. Necesito un desarrollador competente para replicar este EA con un ajuste crítico: debe evitar operar durante las horas de noticias, como lo indica un indicador de noticias específico.( solo tengo el EA en formato EX4) Requisitos clave: - El EA no debe realizar ningún pedido nuevo a

Proje bilgisi

Bütçe
30 - 200 USD
KDV (21%): 6.3 - 42 USD
Toplam: 36.3 - 242 USD
Geliştirici için
27 - 180 USD
Son teslim tarihi
from 1 to 3 gün