
この戦略は,パラパラ線SAR (Stop and Reverse) 指数に基づいた完全な取引システムで,価格トレンドをダイナミックに追跡することによって,買い物決定を行う.このシステムは,クラシックなトレンド追跡方法を採用し,多空の双方向取引の仕組みを組み合わせ,異なる市場環境で価格の動きを捉えることができる.戦略の核心は,SAR指数と価格の交差点を利用して,トレンドの転換点を識別し,適切なタイミングでポジション操作を行うことである.
この戦略は、次の基本原則に基づいて実行されます。
これは,古典的な技術指標に基づいた完全な取引戦略であり,体系化および客観化の特徴を持っています.合理的なパラメータ設定と戦略の最適化により,このシステムは,トレンド市場で優れたパフォーマンスを得ることができます.しかし,ユーザーは,戦略の限界を十分に認識する必要があります.特に,揺れ動いている市場でのパフォーマンスは不十分かもしれません.
/*backtest
start: 2019-12-23 08:00:00
end: 2024-11-25 08:00:00
period: 1d
basePeriod: 1d
exchanges: [{"eid":"Futures_Binance","currency":"BTC_USDT"}]
*/
//@version=5
strategy("LTJ Strategy", overlay=true)
// Parámetros del Parabolic SAR
start = input(0.02, title="Start")
increment = input(0.02, title="Increment")
maximum = input(0.2, title="Maximum")
// Calculando el Parabolic SAR
sar = ta.sar(start, increment, maximum)
// Condiciones para entrar y salir de la posición
longCondition = ta.crossunder(sar, close) // Compra cuando el Parabolic SAR cruza por debajo del precio de cierre
exitLongCondition = ta.crossover(sar, close) // Venta cuando el Parabolic SAR cruza por encima del precio de cierre
// Condiciones para entrar y salir de la posición
shortCondition = ta.crossover(sar, close) // Compra cuando el Parabolic SAR cruza por debajo del precio de cierre
exitShortCondition = ta.crossunder(sar, close) // Venta cuando el Parabolic SAR cruza por encima del precio de cierre
// Ejecutando las órdenes según las condiciones
if (longCondition)
strategy.entry("Buy", strategy.long)
if (exitLongCondition)
strategy.close("Buy")
// Ejecutar las órdenes de venta en corto
if (shortCondition)
strategy.entry("Sell", strategy.short)
if (exitShortCondition)
strategy.close("Sell")
// Opcional: Dibujar el Parabolic SAR en el gráfico para visualización
// Si el SAR está por debajo del precio, lo pintamos de verde; si está por encima, de rojo
colorSar = sar < close ? color.green : color.red
plot(sar, style=plot.style_circles, color=colorSar, linewidth=2, title="Parabolic SAR")