Log in to see Cloud of Tags

Wealth-Lab Wiki

Price Volume Distribution

RSS

Syntax


public static void PriceVolumeDist(this WealthScript obj, int Lookback, Color LineColor, Color FillColor)

public void PriceVolumeDist( int Lookback, System.Color LineColor, System.Color FillColor );

Parameter Description

LookbackNumber of bars used in the distribution
LineColorOutline color of the distribution bars. For no outline, pass the same color as FillColor
FillColor Fill color of the distibution bars

Description

A price-volume distribution is the total volume traded in price ranges (or bins) displayed in relative terms as horizontal bars alongside the right chart axis. The price-volume distribution is calculated for the number of bars specified in the Lookback parameter, as described in the example.

Originally created by Robert Sucher and Dion Kurczek.

Example

The following example plots the Price Volume Distribution with blue lines and a light blue background for the most recent 250 bars:

Price Volume Distribution (Crude Oil continuous contract)

Price Volume Distribution (Crude Oil continuous contract)


Example using C# extension methods:


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

namespace WealthLab.Strategies { public class PriceVolumeDistribution_Test : WealthScript { protected override void Execute() { Color LineColor = Color.Blue; Color FillColor = Color.FromArgb( 30, Color.Blue ); int Lookback = 250; if( Bars.Count < Lookback ) return; this.PriceVolumeDist( Lookback, LineColor, FillColor ); } } }

Legacy syntax example:


using System;
using System.Collections.Generic;
using System.Text;
using System.Drawing;
using WealthLab;
using WealthLab.Indicators; 
using Community.Components; /*** Requires installation of Community.Components Extension from www.wealth-lab.com > Extensions ***/

namespace WealthLab.Strategies { public class PriceVolumeDistribution_Test : WealthScript { protected override void Execute() { Calculate c = new Calculate( this ); Color LineColor = Color.Blue; Color FillColor = Color.FromArgb( 30, Color.Blue ); int Lookback = 250; if( Bars.Count < Lookback ) return; c.PriceVolumeDist( Lookback, LineColor, FillColor ); } } }

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.


ScrewTurn Wiki. Some of the icons created by FamFamFam.