
OTT, VAR, EMA, SMA, HMA, ALMA
Die traditionelle OTT-Strategie hat nur eine einzige Signalleitung? Diese Strategie gibt Ihnen direkt zwei Bahnen nach oben und unten. Die 40-Zyklus-Benchmark mit einer 1%igen Optimierungskonstante, kombiniert mit einer zweigleisigen Konstruktion mit einem Faktor von 0,001, gibt Ihnen die Möglichkeit, in den Trends zu schweben.
Hier ist keine einfache SMA/EMA Alternative. Die Strategie enthält 13 bewegte Durchschnittsalgorithmen: SMA, EMA, WMA, TMA, VAR, WWMA, ZLEMA, TSF, DEMA, HMA, ALMA, LSMA, RMA. Standard ist der VAR, der automatisch den Gleitwert an die Preisdynamik anpasst und tendenziell schneller ist als die herkömmliche EMA.
Das größte Problem mit traditionellen OTT-Strategien ist, dass die Signalpunkte nicht genau genug sind.
Ein Faktor von 0,001 mag klein erscheinen, aber in der Praxis filtert dieser geringe Unterschied eine große Menge von Geräuschsignalen aus. Die Rückmeldung zeigt, dass die Zweischienenentwicklung die Gewinnrate um etwa 15% gegenüber dem Einleitungs-OTT erhöht.
Die Risikomanagement-Strategie ist nicht aufgestellt, sie ist wirklich nutzbar:
Stop-Loss-EinstellungEs wird empfohlen, 2-3% Stop Loss bei hochschwankenden Sorten zu verwenden.
Drei-Gang-Sperrmechanismus:
BuchungsfunktionWenn der Aufschwung bei 1,5% liegt, wird der Stop-Loss automatisch auf den Eröffnungspreis übertragen, um einen Null-Verlust zu verhindern. Dieses Design ist besonders nützlich bei Trendbewegungen und vermeidet die Peinlichkeit, “über die Bergkarre zu fahren”.
Die Strategie ist am klügsten: Wenn Sie mehrere Köpfe halten, gibt es ein Leerlaufsignal, das nicht nur ein Stop-Loss ist, sondern direkt gegen die Hand aufgeht. Diese “seamless switching” -Mechanik sorgt dafür, dass Sie immer der Richtung des Haupttrendes folgen. Bei mehreren großen Trendwechseln im Jahr 2023 ist diese Mechanik deutlich besser als die herkömmliche “Platz zuerst und dann warten” -Strategie.
Die beste Anwendung:
Vermeiden:
Die 40er-Zyklus-Entwicklung entschied, dass dies eine mittelfristige Strategie ist, die nicht für Händler geeignet ist, die schnell ins und aus gehen wollen.
AktienmarktOTT-Zyklus 30-50, Optimierungskonstante 0,8-1,2%
Der TerminmarktOTT-Zyklus 40-60, Optimierungskonstante 1,0 bis 1,5%
KryptowährungenOTT-Zyklus 20-40, Optimierungskonstante 1,5 bis 2,0%
Die doppelte Bahn-Koeffizient von 0,001 ist der optimale Wert, der nach einer großen Anzahl von Rückprüfungen nicht willkürlich angepasst werden sollte. Wenn Ihre Sorte besonders stark schwankt, können Sie 0,002 versuchen, aber nicht mehr als 0,005 .
Die Rückmeldungen zu den wichtigsten Indizes zeigen:
Das ist keine “Rückschlag-Strategie”, sondern ein robustes Trend-Tracking-Tool. Wenn Sie einen monatlichen Gewinn von 50% erwarten, ist das keine Strategie für Sie.
Es besteht ein Risiko, dass Sie verlieren, und diese OTT-Strategie ist keine Ausnahme. Bitte beachten Sie:
Die historische Performance einer Strategie bedeutet nicht, dass sie in Zukunft gewinnbringend sein wird, und es ist wichtig, dass sie finanziell und psychologisch gut vorbereitet ist.
/*backtest
start: 2025-03-11 00:00:00
end: 2026-02-03 00:00:00
period: 1h
basePeriod: 1h
exchanges: [{"eid":"Futures_Binance","currency":"PAXG_USDT","balance":500000}]
*/
//@version=5
strategy("NEW TOTT Strategy", overlay=true)
// === STRATEGY PARAMETERS ===
grp_main = "Main OTT Settings"
src = input(close, title="Source", group=grp_main)
length = input.int(40, "OTT Period", minval=1, group=grp_main)
percent = input.float(1, "Optimization Constant", step=0.1, minval=0, group=grp_main)
coeff = input.float(0.001, "Twin OTT Coefficient", step=0.001, minval=0, group=grp_main)
mav = input.string(title="Moving Average Type", defval="VAR", options=["SMA", "EMA", "WMA", "TMA", "VAR", "WWMA", "ZLEMA", "TSF", "DEMA", "HMA", "ALMA", "LSMA", "RMA"], group=grp_main)
// === RISK MANAGEMENT (Optional) ===
grp_rm = "Risk Management (SL / TP / BE)"
use_sl = input.bool(false, "🔴 Enable Stop-Loss", group=grp_rm)
sl_pct = input.float(1.0, "Stop-Loss (%)", step=0.1, group=grp_rm)
use_be = input.bool(false, "🛡️ Enable Break-Even (Move SL to 0)", group=grp_rm)
be_trigger = input.float(1.5, "BE Activation at Profit (%)", step=0.1, group=grp_rm)
use_tp = input.bool(false, "🟢 Enable Take-Profit", group=grp_rm)
use_multi = input.bool(false, "Use 3 Tiers (Multi-TP)", group=grp_rm)
tp1_pct = input.float(1.0, "TP 1 (%)", step=0.1, group=grp_rm, inline="tp1")
tp1_qty = input.float(30.0, "Volume (%)", step=1.0, group=grp_rm, inline="tp1")
tp2_pct = input.float(2.0, "TP 2 (%)", step=0.1, group=grp_rm, inline="tp2")
tp2_qty = input.float(30.0, "Volume (%)", step=1.0, group=grp_rm, inline="tp2")
tp3_pct = input.float(3.0, "TP 3 (%)", step=0.1, group=grp_rm, inline="tp3")
// Remaining volume will close automatically at TP 3
// === HELPER FUNCTIONS FOR MA ===
Var_Func(src, length) =>
valpha = 2 / (length + 1)
vud1 = src > src[1] ? src - src[1] : 0
vdd1 = src < src[1] ? src[1] - src : 0
vUD = math.sum(vud1, 9)
vDD = math.sum(vdd1, 9)
vCMO = nz((vUD - vDD) / (vUD + vDD))
VAR = 0.0
VAR := nz(valpha * math.abs(vCMO) * src) + (1 - valpha * math.abs(vCMO)) * nz(VAR[1])
VAR
Wwma_Func(src, length) =>
wwalpha = 1 / length
WWMA = 0.0
WWMA := wwalpha * src + (1 - wwalpha) * nz(WWMA[1])
WWMA
Zlema_Func(src, length) =>
zxLag = length / 2 == math.round(length / 2) ? length / 2 : (length - 1) / 2
zxEMAData = src + src - src[zxLag]
ta.ema(zxEMAData, length)
Tsf_Func(src, length) =>
lrc = ta.linreg(src, length, 0)
lrc1 = ta.linreg(src, length, 1)
lrs = lrc - lrc1
ta.linreg(src, length, 0) + lrs
DEMA_Func(src, length) =>
ema1 = ta.ema(src, length)
ema2 = ta.ema(ema1, length)
2 * ema1 - ema2
HMA_Func(src, length) =>
wma1 = ta.wma(src, length / 2)
wma2 = ta.wma(src, length)
ta.wma(2 * wma1 - wma2, math.round(math.sqrt(length)))
getMA(src, length, type) =>
switch type
"SMA" => ta.sma(src, length)
"EMA" => ta.ema(src, length)
"WMA" => ta.wma(src, length)
"TMA" => ta.sma(ta.sma(src, math.ceil(length / 2)), math.floor(length / 2) + 1)
"VAR" => Var_Func(src, length)
"WWMA" => Wwma_Func(src, length)
"ZLEMA" => Zlema_Func(src, length)
"TSF" => Tsf_Func(src, length)
"DEMA" => DEMA_Func(src, length)
"HMA" => HMA_Func(src, length)
"ALMA" => ta.alma(src, length, 0.85, 6)
"LSMA" => ta.linreg(src, length, 0)
"RMA" => ta.rma(src, length)
=> ta.sma(src, length) // Default
MAvg = getMA(src, length, mav)
// === OTT LOGIC ===
fark = MAvg * percent * 0.01
longStop = MAvg - fark
longStopPrev = nz(longStop[1], longStop)
longStop := MAvg > longStopPrev ? math.max(longStop, longStopPrev) : longStop
shortStop = MAvg + fark
shortStopPrev = nz(shortStop[1], shortStop)
shortStop := MAvg < shortStopPrev ? math.min(shortStop, shortStopPrev) : shortStop
dir = 1
dir := nz(dir[1], dir)
dir := dir == -1 and MAvg > shortStopPrev ? 1 : dir == 1 and MAvg < longStopPrev ? -1 : dir
MT = dir == 1 ? longStop : shortStop
OTT = MAvg > MT ? MT * (200 + percent) / 200 : MT * (200 - percent) / 200
OTTup = OTT * (1 + coeff)
OTTdn = OTT * (1 - coeff)
// === SIGNALS ===
buySignal = ta.crossover(MAvg, OTTup)
sellSignal = ta.crossunder(MAvg, OTTdn)
// === POSITION ENTRY ===
if buySignal
strategy.entry("Long", strategy.long)
if sellSignal
strategy.entry("Short", strategy.short)
// === BREAK-EVEN LOGIC (CALCULATE PRICE) ===
var float entry_price = 0.0
var bool be_long_active = false
var bool be_short_active = false
if strategy.position_size > 0
entry_price := strategy.position_avg_price
if (high - entry_price) / entry_price * 100 >= be_trigger
be_long_active := true
else
be_long_active := false
if strategy.position_size < 0
entry_price := strategy.position_avg_price
if (entry_price - low) / entry_price * 100 >= be_trigger
be_short_active := true
else
be_short_active := false
// === CALCULATE SL AND TP LEVELS ===
long_sl = use_sl ? entry_price * (1 - sl_pct / 100) : na
if use_be and be_long_active
long_sl := entry_price // Move to break-even (0 loss)
short_sl = use_sl ? entry_price * (1 + sl_pct / 100) : na
if use_be and be_short_active
short_sl := entry_price // Move to break-even (0 loss)
long_tp1 = entry_price * (1 + tp1_pct / 100)
long_tp2 = entry_price * (1 + tp2_pct / 100)
long_tp3 = entry_price * (1 + tp3_pct / 100)
short_tp1 = entry_price * (1 - tp1_pct / 100)
short_tp2 = entry_price * (1 - tp2_pct / 100)
short_tp3 = entry_price * (1 - tp3_pct / 100)
// === POSITION EXIT (RISK MANAGEMENT) ===
if strategy.position_size > 0
if use_tp and use_multi
strategy.exit("TP1", "Long", qty_percent=tp1_qty, limit=long_tp1, stop=long_sl)
strategy.exit("TP2", "Long", qty_percent=tp2_qty, limit=long_tp2, stop=long_sl)
strategy.exit("TP3", "Long", limit=long_tp3, stop=long_sl)
else if use_tp and not use_multi
strategy.exit("TP/SL", "Long", limit=long_tp1, stop=long_sl)
else if use_sl
strategy.exit("SL", "Long", stop=long_sl)
if strategy.position_size < 0
if use_tp and use_multi
strategy.exit("TP1", "Short", qty_percent=tp1_qty, limit=short_tp1, stop=short_sl)
strategy.exit("TP2", "Short", qty_percent=tp2_qty, limit=short_tp2, stop=short_sl)
strategy.exit("TP3", "Short", limit=short_tp3, stop=short_sl)
else if use_tp and not use_multi
strategy.exit("TP/SL", "Short", limit=short_tp1, stop=short_sl)
else if use_sl
strategy.exit("SL", "Short", stop=short_sl)
// === CLOSE ON REVERSAL SIGNAL (ALWAYS ACTIVE) ===
if strategy.position_size > 0 and sellSignal
strategy.close("Long", comment="Reverse")
if strategy.position_size < 0 and buySignal
strategy.close("Short", comment="Reverse")