mirror of
https://github.com/mihakralj/QuanTAlib.git
synced 2026-08-15 09:08:04 +00:00
more volatilty
This commit is contained in:
+26
-26
@@ -6,29 +6,29 @@ Volume is market fuel. Price tells what happened; volume tells how hard the mark
|
||||
|
||||
| Indicator | Full Name | Description |
|
||||
| :--- | :--- | :--- |
|
||||
| [ADL](lib/volume/adl/Adl.md) | Accumulation/Distribution Line | Correlates price location within range to volume. Grandfather of volume flow analysis. |
|
||||
| [ADOSC](lib/volume/adosc/Adosc.md) | Chaikin A/D Oscillator | Momentum indicator for AD Line. Predicts reversals by measuring acceleration of money flow. |
|
||||
| [AOBV](lib/volume/aobv/Aobv.md) | Archer On-Balance Volume | Dual EMA smoothing of OBV for cleaner crossover signals. |
|
||||
| [CMF](lib/volume/cmf/Cmf.md) | Chaikin Money Flow | Measures money flow volume over set period (typically 20-21 days). |
|
||||
| [EFI](lib/volume/efi/Efi.md) | Elder's Force Index | Combines price movement, direction, volume to measure buying/selling power. |
|
||||
| [EOM](lib/volume/eom/Eom.md) | Ease of Movement | Relates price change to volume. Highlights periods of effortless price movement. |
|
||||
| [III](lib/volume/iii/Iii.md) | Intraday Intensity Index | Measures buying/selling pressure within day's range using close position. |
|
||||
| [KVO](lib/volume/kvo/Kvo.md) | Klinger Volume Oscillator | Compares short-term and long-term volume trends to identify potential reversals. |
|
||||
| [MFI](lib/volume/mfi/Mfi.md) | Money Flow Index | Volume-weighted RSI. Measures buying/selling pressure using price and volume. |
|
||||
| [NVI](lib/volume/nvi/Nvi.md) | Negative Volume Index | Tracks price changes on lower volume days. Assumes smart money acts on quiet days. |
|
||||
| [OBV](lib/volume/obv/Obv.md) | On Balance Volume | Fundamental volume indicator. Cumulative volume based on price direction. |
|
||||
| [PVD](lib/volume/pvd/Pvd.md) | Price Volume Divergence | Systematic divergence detection between price and volume movements. |
|
||||
| [PVI](lib/volume/pvi/Pvi.md) | Positive Volume Index | Tracks price changes on higher volume days. Assumes crowd behavior. |
|
||||
| [PVO](lib/volume/pvo/Pvo.md) | Percentage Volume Oscillator | Compares short-term and long-term volume moving averages as percentages. |
|
||||
| [PVR](lib/volume/pvr/Pvr.md) | Price Volume Rank | Categorical indicator returning 0-4 based on combined price and volume direction. |
|
||||
| [PVT](lib/volume/pvt/Pvt.md) | Price Volume Trend | Cumulative volume adjusted by relative price changes. Similar to OBV but magnitude-weighted. |
|
||||
| [TVI](lib/volume/tvi/Tvi.md) | Trade Volume Index | Cumulative volume with sticky direction based on minimum tick threshold. Filters noise from OBV. |
|
||||
| [TWAP](lib/volume/twap/Twap.md) | Time Weighted Average Price | Average price weighted equally by time. Used as execution benchmark. |
|
||||
| [VA](lib/volume/va/Va.md) | Volume Accumulation | Cumulative volume adjusted by close position relative to range midpoint. |
|
||||
| [VF](lib/volume/vf/Vf.md) | Volume Force | Measures force of volume behind price movements using EMA smoothing. |
|
||||
| [VO](lib/volume/vo/Vo.md) | Volume Oscillator | Difference between short and long volume moving averages. Shows volume momentum. |
|
||||
| [VROC](lib/volume/vroc/Vroc.md) | Volume Rate of Change | Measures speed at which volume is changing over time. |
|
||||
| [VWAD](lib/volume/vwad/Vwad.md) | Volume Weighted A/D | Similar to ADL but weights accumulation/distribution by volume. |
|
||||
| [VWAP](lib/volume/vwap/Vwap.md) | Volume Weighted Average Price | Average price weighted by volume. Common execution benchmark and intraday reference. |
|
||||
| [VWMA](lib/volume/vwma/Vwma.md) | Volume Weighted Moving Average | Moving average where each price point is weighted by its volume over a sliding window. |
|
||||
| [WAD](lib/volume/wad/Wad.md) | Williams Accumulation/Distribution | Measures cumulative buying/selling pressure using True Range and volume. |
|
||||
| [ADL](/lib/volume/adl/Adl.md) | Accumulation/Distribution Line | Correlates price location within range to volume. Grandfather of volume flow analysis. |
|
||||
| [ADOSC](/lib/volume/adosc/Adosc.md) | Chaikin A/D Oscillator | Momentum indicator for AD Line. Predicts reversals by measuring acceleration of money flow. |
|
||||
| [AOBV](/lib/volume/aobv/Aobv.md) | Archer On-Balance Volume | Dual EMA smoothing of OBV for cleaner crossover signals. |
|
||||
| [CMF](/lib/volume/cmf/Cmf.md) | Chaikin Money Flow | Measures money flow volume over set period (typically 20-21 days). |
|
||||
| [EFI](/lib/volume/efi/Efi.md) | Elder's Force Index | Combines price movement, direction, volume to measure buying/selling power. |
|
||||
| [EOM](/lib/volume/eom/Eom.md) | Ease of Movement | Relates price change to volume. Highlights periods of effortless price movement. |
|
||||
| [III](/lib/volume/iii/Iii.md) | Intraday Intensity Index | Measures buying/selling pressure within day's range using close position. |
|
||||
| [KVO](/lib/volume/kvo/Kvo.md) | Klinger Volume Oscillator | Compares short-term and long-term volume trends to identify potential reversals. |
|
||||
| [MFI](/lib/volume/mfi/Mfi.md) | Money Flow Index | Volume-weighted RSI. Measures buying/selling pressure using price and volume. |
|
||||
| [NVI](/lib/volume/nvi/Nvi.md) | Negative Volume Index | Tracks price changes on lower volume days. Assumes smart money acts on quiet days. |
|
||||
| [OBV](/lib/volume/obv/Obv.md) | On Balance Volume | Fundamental volume indicator. Cumulative volume based on price direction. |
|
||||
| [PVD](/lib/volume/pvd/Pvd.md) | Price Volume Divergence | Systematic divergence detection between price and volume movements. |
|
||||
| [PVI](/lib/volume/pvi/Pvi.md) | Positive Volume Index | Tracks price changes on higher volume days. Assumes crowd behavior. |
|
||||
| [PVO](/lib/volume/pvo/Pvo.md) | Percentage Volume Oscillator | Compares short-term and long-term volume moving averages as percentages. |
|
||||
| [PVR](/lib/volume/pvr/Pvr.md) | Price Volume Rank | Categorical indicator returning 0-4 based on combined price and volume direction. |
|
||||
| [PVT](/lib/volume/pvt/Pvt.md) | Price Volume Trend | Cumulative volume adjusted by relative price changes. Similar to OBV but magnitude-weighted. |
|
||||
| [TVI](/lib/volume/tvi/Tvi.md) | Trade Volume Index | Cumulative volume with sticky direction based on minimum tick threshold. Filters noise from OBV. |
|
||||
| [TWAP](/lib/volume/twap/Twap.md) | Time Weighted Average Price | Average price weighted equally by time. Used as execution benchmark. |
|
||||
| [VA](/lib/volume/va/Va.md) | Volume Accumulation | Cumulative volume adjusted by close position relative to range midpoint. |
|
||||
| [VF](/lib/volume/vf/Vf.md) | Volume Force | Measures force of volume behind price movements using EMA smoothing. |
|
||||
| [VO](/lib/volume/vo/Vo.md) | Volume Oscillator | Difference between short and long volume moving averages. Shows volume momentum. |
|
||||
| [VROC](/lib/volume/vroc/Vroc.md) | Volume Rate of Change | Measures speed at which volume is changing over time. |
|
||||
| [VWAD](/lib/volume/vwad/Vwad.md) | Volume Weighted A/D | Similar to ADL but weights accumulation/distribution by volume. |
|
||||
| [VWAP](/lib/volume/vwap/Vwap.md) | Volume Weighted Average Price | Average price weighted by volume. Common execution benchmark and intraday reference. |
|
||||
| [VWMA](/lib/volume/vwma/Vwma.md) | Volume Weighted Moving Average | Moving average where each price point is weighted by its volume over a sliding window. |
|
||||
| [WAD](/lib/volume/wad/Wad.md) | Williams Accumulation/Distribution | Measures cumulative buying/selling pressure using True Range and volume. |
|
||||
|
||||
+4
-11
@@ -145,7 +145,10 @@ public sealed class Aobv : ITValuePublisher
|
||||
// Calculate OBV
|
||||
if (s.Index == 0)
|
||||
{
|
||||
s.Obv = 0; // First bar, no comparison - matches span Calculate
|
||||
// First bar initialization - all values start at 0
|
||||
s.Obv = 0;
|
||||
s.EmaFast = 0;
|
||||
s.EmaSlow = 0;
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -161,11 +164,6 @@ public sealed class Aobv : ITValuePublisher
|
||||
}
|
||||
|
||||
// Calculate EMA Fast with warmup compensation
|
||||
if (s.Index == 0)
|
||||
{
|
||||
s.EmaFast = 0;
|
||||
}
|
||||
|
||||
s.EmaFast = Math.FusedMultiplyAdd(_alphaFast, s.Obv - s.EmaFast, s.EmaFast);
|
||||
|
||||
double resultFast;
|
||||
@@ -185,11 +183,6 @@ public sealed class Aobv : ITValuePublisher
|
||||
}
|
||||
|
||||
// Calculate EMA Slow with warmup compensation
|
||||
if (s.Index == 0)
|
||||
{
|
||||
s.EmaSlow = 0;
|
||||
}
|
||||
|
||||
s.EmaSlow = Math.FusedMultiplyAdd(_alphaSlow, s.Obv - s.EmaSlow, s.EmaSlow);
|
||||
|
||||
double resultSlow;
|
||||
|
||||
@@ -105,7 +105,7 @@ public sealed class Eom : ITValuePublisher
|
||||
if (priceRange > 0 && volume > 0)
|
||||
{
|
||||
double boxRatio = (volume / _volumeScale) / priceRange;
|
||||
rawEom = boxRatio != 0 ? midPointChange / boxRatio : 0.0;
|
||||
rawEom = Math.Abs(boxRatio) > 0 ? midPointChange / boxRatio : 0.0;
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -293,7 +293,7 @@ public sealed class Eom : ITValuePublisher
|
||||
if (priceRange > 0 && volume[i] > 0)
|
||||
{
|
||||
double boxRatio = (volume[i] / volumeScale) / priceRange;
|
||||
rawEom[i] = boxRatio != 0 ? midPointChange / boxRatio : 0.0;
|
||||
rawEom[i] = Math.Abs(boxRatio) > 0 ? midPointChange / boxRatio : 0.0;
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
@@ -172,7 +172,7 @@ public sealed class Pvo : ITValuePublisher
|
||||
}
|
||||
|
||||
// Calculate PVO: ((fastEMA - slowEMA) / slowEMA) * 100
|
||||
double pvoValue = slowComp != 0.0 ? ((fastComp - slowComp) / slowComp) * 100.0 : 0.0;
|
||||
double pvoValue = Math.Abs(slowComp) > 0 ? ((fastComp - slowComp) / slowComp) * 100.0 : 0.0;
|
||||
|
||||
// Update signal EMA
|
||||
s.EmaSignal = Math.FusedMultiplyAdd(_alphaSignal, pvoValue - s.EmaSignal, s.EmaSignal);
|
||||
@@ -386,7 +386,7 @@ public sealed class Pvo : ITValuePublisher
|
||||
}
|
||||
|
||||
// Calculate PVO
|
||||
double pvoValue = slowComp != 0.0 ? ((fastComp - slowComp) / slowComp) * 100.0 : 0.0;
|
||||
double pvoValue = Math.Abs(slowComp) > 0 ? ((fastComp - slowComp) / slowComp) * 100.0 : 0.0;
|
||||
output[i] = pvoValue;
|
||||
|
||||
// Update signal EMA
|
||||
|
||||
Reference in New Issue
Block a user