
이 전략은 Negative Volume Index Reversal 전략이라고 불린다. 이 전략은 Negative Volume Index Reversal 전략에 속한다. Negative Volume Index Reversal 전략은 Negative Volume Index Reversal 전략에 속한다. Negative Volume Index Reversal 전략은 Negative Volume Index Reversal 전략에 속한다.
마이너스 지표 역전 전략의 핵심 지표는 마이너스 지표 ((NVI) 。NVI의 계산 공식은:
당일 거래량 < 전날 거래량: NVI = 전날 NVI + 당일 가격 변화율
당일 통행량 >= 전날 통행량: NVI = 전날 NVI
즉, NVI는 거래량이 축소된 날에만 업데이트되며, 가격 변화율을 더하거나 줄임으로써 가격 움직임을 반영한다. 그리고 NVI가 장단 신호를 구성하는 논리는 다음과 같다:
그래서, 수치가 줄어들면서 역거래를 할 수 있습니다.
마이너스 지표 반전 전략의 주요 장점은 다음과 같습니다.
트래픽 신호를 이용하면 역전점을 찾을 수 있으며, 특정 시점의 장점을 가지고 있다.
전략의 논리는 간단하고 이해하기 쉽고 실행이 쉽다.
다른 시장 환경에 적응하기 위해 파라미터를 조정하여 최적화 할 수 있습니다.
하지만 이 전략에는 몇 가지 위험도 있습니다.
거래량 신호의 정확성은 보장할 수 없으며, 잘못된 거래의 일정한 확률이 있다.
잘못된 매개 변수 설정으로 인해 거래가 너무 빈번하거나 신호가 잘 보이지 않을 수 있습니다.
데이터의 출처를 확실하게 하고, 거래량 데이터 오류의 위험을 피해야 합니다.
이러한 위험은 변수 최적화와 Stop Loss 전략과 같은 방법으로 줄일 수 있습니다.
마이너스 지표 반전 전략은 다음과 같은 측면에서 최적화될 수 있다:
이동 평균 변수를 최적화하여 시장의 특성을 더 잘 설명하는 변수를 찾습니다.
다른 지표에 필터를 추가하여 불필요한 잘못된 거래를 피하십시오. 예를 들어, 확대 레벨 트렌드 판단.
단독 손실을 제한하기 위해 강력한 손해 방지 방법을 사용한다.
다양한 품종의 변수 설정 차이를 테스트하고, 적응 변수를 설정한다.
마이너스 지표 역전 전략은 거래량이 축소되는 동안 역전 작업을 수행하여 잠재적인 트렌드 역전점을 포착하는 것을 목표로 한다. 이 전략은 간단하고 이해하기 쉬운 장점이 있지만, 동시에 잘못된 거래의 위험이 있다. 매개 변수 최적화, 보조 지표를 추가하는 등의 방법으로 전략의 안정성과 수익성을 향상시킬 수 있다.
/*backtest
start: 2023-12-13 00:00:00
end: 2023-12-20 00:00:00
period: 30m
basePeriod: 15m
exchanges: [{"eid":"Futures_Binance","currency":"BTC_USDT"}]
*/
//@version=2
////////////////////////////////////////////////////////////
// Copyright by HPotter 11/08/2017
// The theory behind the indexes is as follows: On days of increasing
// volume, you can expect prices to increase, and on days of decreasing
// volume, you can expect prices to decrease. This goes with the idea of
// the market being in-gear and out-of-gear. Both PVI and NVI work in similar
// fashions: Both are a running cumulative of values, which means you either
// keep adding or subtracting price rate of change each day to the previous day`s
// sum. In the case of PVI, if today`s volume is less than yesterday`s, don`t add
// anything; if today`s volume is greater, then add today`s price rate of change.
// For NVI, add today`s price rate of change only if today`s volume is less than
// yesterday`s.
//
// You can change long to short in the Input Settings
// Please, use it only for learning or paper trading. Do not for real trading.
////////////////////////////////////////////////////////////
strategy(title="Negative Volume Index Backtest", shorttitle="NVI Str")
EMA_Len = input(255, minval=1)
reverse = input(false, title="Trade reverse")
xROC = roc(close, 1)
nRes = iff(volume < volume[1], nz(nRes[1], 0) + xROC, nz(nRes[1], 0))
nResEMA = ema(nRes, EMA_Len)
pos = iff(nRes > nResEMA, 1,
iff(nRes < nResEMA, -1, nz(pos[1], 0)))
possig = iff(reverse and pos == 1, -1,
iff(reverse and pos == -1, 1, pos))
if (possig == 1)
strategy.entry("Long", strategy.long)
if (possig == -1)
strategy.entry("Short", strategy.short)
barcolor(possig == -1 ? red: possig == 1 ? green : blue )
plot(nRes, color=red, title="NVI")
plot(nResEMA, color=blue, title="EMA")