
Esta es una estrategia de negociación basada en el indicador cuantitativo de Klinger. La estrategia capta los cambios en las fuerzas de compra y venta en las fluctuaciones de precios para descubrir los puntos de inflexión de las tendencias del mercado. Sus ventajas son la sensibilidad y la precisión, que se pueden aplicar tanto al análisis a corto como a largo plazo.
La estrategia se basa en las siguientes teorías:
De acuerdo con estas teorías, la estrategia calcula el indicador cuantitativo de Klinger mediante la comparación de la suma de los precios de cierre y la relación de magnitud con el día anterior, combinando los cambios de volumen de negocios.
En concreto, la estrategia incluye tres indicadores:
Luego se calcula el diferencial xKVO como indicador de la operación. Cuando se usa la línea media de 13 días xTrigger, se hace más y cuando se usa la línea media de 13 días, se hace vacío.
La mayor ventaja de esta estrategia es que es adecuada tanto para el análisis a corto como a largo plazo. La configuración de los parámetros de la línea media lenta y rápida le permite capturar de manera sensible los cambios en las tendencias a corto plazo. Al mismo tiempo, también puede filtrar el ruido del mercado a corto plazo y capturar las tendencias a largo plazo.
Además, la estrategia se basa solo en el cálculo de precios y volúmenes de transacción. No se requiere el cálculo de indicadores matemáticos complejos, la eficiencia de cálculo es alta y es adecuada para aplicaciones en el mercado.
El mayor riesgo de esta estrategia reside en la débil capacidad de los indicadores de volumen de transacción para detectar falsas rupturas. La estrategia puede emitir una señal de multiplicación errónea cuando el precio se ajusta a corto plazo para romper la línea media.
Además, la estrategia es más sensible a la configuración de parámetros. Los parámetros de las líneas medias rápidas y lentas y las líneas medias de transacción necesitan ser repetidamente probados y optimizados para obtener el mejor rendimiento.
De acuerdo con el análisis de riesgos, podemos optimizar aún más la estrategia en los siguientes aspectos:
Aumentar el mecanismo de suspensión de pérdidas. La suspensión de pérdidas cuando el precio retrocede en una cierta proporción, puede reducir la interferencia de ruido de ajuste a corto plazo.
Aumentar los indicadores de filtración de tendencias. En combinación con indicadores como el MACD y los indicadores de medias móviles para determinar el movimiento general del mercado y evitar el desvío en situaciones de crisis.
Optimización de la configuración de los parámetros. Buscar la combinación óptima de parámetros a través de datos de retroalimentación histórica para mejorar la estabilidad de la estrategia.
Optimización de la administración de fondos a corto plazo. Por ejemplo, ajuste dinámico de posiciones en función de la situación de stop loss y stop win.
Esta estrategia capta los cambios en las fuerzas de compra y venta en el mercado al mismo tiempo que tiene en cuenta la sensibilidad y la estabilidad al comparar la relación entre el volumen total de precios y el volumen de transacciones. Se puede obtener un buen rendimiento si se establecen parámetros de optimización y se combina con el juicio de tendencias.
||
This is a trading strategy based on the Klinger Volume Oscillator. It captures the shifts in buying and selling forces during price fluctuations to identify turning points in market trends. The advantages are sensitivity and accuracy for both short-term and long-term analysis. However, some risks need to be noticed.
The strategy is built on the following assumptions:
Based on the theories, the strategy calculates the Klinger Volume Oscillator by comparing the relationship between today’s sum of closing prices and yesterday’s, combined with changes in volume. It goes long when the indicator crosses above its moving average line, and goes short on crosses below.
Specifically, there are three main indicators involved:
The difference xKVO is then calculated as the trading indicator. Go long on crossing above 13-day EMA xTrigger, and short on crossing below.
The greatest advantage is being suitable for both short-term and long-term analysis simultaneously. The fast and slow EMA settings make it sensitive to catch short-term swings, while also filtering out market noise and capturing long-term trends, which most price-based indicators struggle with.
In addition, it is purely based on price and volume data without complex math. This makes it highly efficient for actual trading applications.
The main risk is weaker ability to distinguish false breakouts. Short-term price adjustments may generate wrong long signals. Other factors should be considered to determine the trend.
Also, the strategy is sensitive towards parameter tuning. Optimization is required on the EMAs and trigger line to find best performance.
Some aspects that could further optimize the strategy according to the risks:
Add stop loss mechanisms. Exiting at some percentage retracement reduces noise interference.
Add trend filtering with indicators like MACD to avoid directional mistakes in ranging markets.
Optimize parameter sets through backtests to improve robustness.
Capital management optimization such as dynamic position sizing based on stop loss/take profit levels.
Overall, the strategy captures shifts in market forces by comparing price quantities and volumes for both sensitivity and stability. It can perform well given optimized parameters and trend validation, but inherent limitations of volume indicators can still pose risks for traders.
[/trans]
/*backtest
start: 2022-11-28 00:00:00
end: 2023-12-04 00:00:00
period: 1d
basePeriod: 1h
exchanges: [{"eid":"Futures_Binance","currency":"BTC_USDT"}]
*/
//@version=2
////////////////////////////////////////////////////////////
// Copyright by HPotter v1.0 30/08/2017
// The Klinger Oscillator (KO) was developed by Stephen J. Klinger. Learning
// from prior research on volume by such well-known technicians as Joseph Granville,
// Larry Williams, and Marc Chaikin, Mr. Klinger set out to develop a volume-based
// indicator to help in both short- and long-term analysis.
// The KO was developed with two seemingly opposite goals in mind: to be sensitive
// enough to signal short-term tops and bottoms, yet accurate enough to reflect the
// long-term flow of money into and out of a security.
// The KO is based on the following tenets:
// Price range (i.e. High - Low) is a measure of movement and volume is the force behind
// the movement. The sum of High + Low + Close defines a trend. Accumulation occurs when
// today's sum is greater than the previous day's. Conversely, distribution occurs when
// today's sum is less than the previous day's. When the sums are equal, the existing trend
// is maintained.
// Volume produces continuous intra-day changes in price reflecting buying and selling pressure.
// The KO quantifies the difference between the number of shares being accumulated and distributed
// each day as "volume force". A strong, rising volume force should accompany an uptrend and then
// gradually contract over time during the latter stages of the uptrend and the early stages of
// the following downtrend. This should be followed by a rising volume force reflecting some
// accumulation before a bottom develops.
//
// You can change long to short in the Input Settings
// Please, use it only for learning or paper trading.
////////////////////////////////////////////////////////////
strategy(title="Klinger Volume Oscillator (KVO)", shorttitle="KVO")
TrigLen = input(13, minval=1)
FastX = input(34, minval=1)
SlowX = input(55, minval=1)
reverse = input(false, title="Trade reverse")
hline(0, color=gray, linestyle=line)
xTrend = iff(hlc3 > hlc3[1], volume * 100, -volume * 100)
xFast = ema(xTrend, FastX)
xSlow = ema(xTrend, SlowX)
xKVO = xFast - xSlow
xTrigger = ema(xKVO, TrigLen)
pos = iff(xKVO > xTrigger, 1,
iff(xKVO < xTrigger, -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(xKVO, color=blue, title="KVO")
plot(xTrigger, color=red, title="Trigger")