Wealth-Lab Wiki

API ChartStyles Community Components Community Indicators IndexDefinitions Knowledge Base Misc Optimizers Pending Deletion PosSizers Providers Standard Indicators TASC Traders Tips TASCIndicators Tutorial Videos Visualizers
RSS

Navigation


Quick Search
»
Advanced Search »


Syntax

public static Vidya Series(DataSeries source, int stdDevPeriod, double alpha)
public Vidya(DataSeries source, int stdDevPeriod, double alpha, string description)
public Vidya(DataSeries source, DataSeries volatilityIndex, double alpha, string description)

Parameter Description



source The source DataSeries
alpha A floating point Alpha parameter
stdDevPeriod StdDev period
volatilityIndex An indicator that tracks market volatility

Description

Vidya returns Tushar Chande's Variable Index Dynamic Average. Vidya is similar to an Exponential Moving Average, EMA, but uses a different period for each bar of calculation. The period to use is determined by the bar's volatility. Bars with a high volatility will use a shorter period, and those with a low volatility a longer period. This results in an indicator that is very responsive to abrupt market moves, but becomes less responsive during consolidation periods.

Vidya requires a "Volatility Index", which should be some indicator that tracks market volatility. Specify the Volatility Index as a DataSeries in the volatilityIndex parameter. The resulting Vidya will have lower effective periods on bars where the Index indicates high volatility.

Vidya also requires a floating point alpha parameter. The values of the Volatility Index are multiplied by alpha to modulate the sensitivity of the Vidya. You should arrive at a value of alpha such that (1 - α * Volatility Index) never becomes negative.

Interpretation

You can interpret Vidya as you would another moving average. Additionally, Vidya tends to respond more quickly and go flat during consolidation periods.

Example

using System;
using System.Collections.Generic;
using System.Text;
using System.Drawing;
using WealthLab;
using WealthLab.Indicators;

namespace WealthLab.Strategies { public class MyStrategy : WealthScript { protected override void Execute() { // Vidya bands DataSeries VidyaStdDev = Vidya.Series( Close, 2, 0.1 ); PlotSeries( PricePane, VidyaStdDev, Color.Red, WealthLab.LineStyle.Dashed, 1 ); DrawLabel( PricePane, "Vidya Bands at 3%", Color.Red ); PlotSeriesDualFillBand( PricePane, VidyaStdDev*1.03, VidyaStdDev*0.97, Color.FromArgb(15,255,0,0), Color.Empty, Color.Empty, LineStyle.Solid, 1 ); } } }

Important Disclaimer: The information provided by Wealth-Lab is strictly for informational purposes and is not to be construed as advice or solicitation to buy or sell any security.  The owner of Wealth-Lab.com assumes no liability resulting from the use of the material contained herein for investment purposes. By using this web site, you agree to the terms of this disclaimer and our Terms of Use.

Used under license from FMR Corp. Copyright 2008 FMR Corp. All rights reserved.


ScrewTurn Wiki. Some of the icons created by FamFamFam.