Conversione dell’indicator VPN dal software di trading Tradestation

Viewing 1 post (of 1 total)
  • Author
    Posts
  • #187910 quote
    guido1997
    Participant
    New

    Codice su Tradestation dell’indicatore volume positive negative, pubblicato sul TASC di Aprile del 2021 di Markos Katsanos.

    Function: _TASC_2021_APR_Fx
    // TASC APR 2021
    // Detecting High-Volume Breakouts
    // Markos Katsanos

    inputs:
    Period( numericsimple );

    variables:
    MAV( 0 ),
    VP( 0 ),
    VN( 0 ),
    VPN( 0 );

    switch ( BarType )
    begin
    case 2,3,4: { Daily, Weekly, or Monthly bars }
    MAV = Average( Volume, Period );
    VP = SummationIf( TypicalPrice –
    TypicalPrice[1] > 0.1 *
    AvgTrueRange( Period ),
    Volume , Period );
    VN = SummationIf( TypicalPrice –
    TypicalPrice[1] < -0.1 * AvgTrueRange( Period ), Ticks , Period ); default: { all other bars } MAV = Average( Ticks, Period ); VP = SummationIf( TypicalPrice - TypicalPrice[1] > 0.1 *
    AvgTrueRange( Period ),
    Ticks , Period );
    VN = SummationIf( TypicalPrice –
    TypicalPrice[1] < -0.1 * AvgTrueRange( Period ), Ticks , Period ); end; if MAV <= 0 then MAV = 1; if Period <> 0 then
    VPN = ( VP – VN ) / MAV / Period * 100;

    _TASC_2021_APR_Fx = VPN;

    Indicator: TASC APR 2021
    // TASC APR 2021
    // Detecting High-Volume Breakouts
    // Markos Katsanos

    inputs:
    Period( 30 ),
    Smooth( 3 ),
    VPNCrit( 10 ),
    MAB( 30 );

    variables:
    VPN( 0 ),
    MAVPN( 0 );

    VPN = XAverage( _TASC_2021_APR_Fx( Period ), Smooth );
    MAVPN = Average( VPN, MAB );

    if VPN >= VPNCrit then
    SetPlotColor[1]( 1, Green )
    else
    SetPlotColor[1]( 1, Red );

    Plot1( VPN, “VPN” );
    Plot2( MAVPN, “MA”, Green );
    Plot3( VPNCrit, “CRIT”, Blue );

    TT-Tradestation-4.png TT-Tradestation-4.png
Viewing 1 post (of 1 total)
  • You must be logged in to reply to this topic.

Conversione dell’indicator VPN dal software di trading Tradestation


ProBuilder: Indicatori & Strumenti Personalizzati

New Reply
Author
author-avatar
guido1997 @guido1997 Participant
Summary

This topic contains 1 voice and has 0 replies.

Topic Details
Forum: ProBuilder: Indicatori & Strumenti Personalizzati
Language: Italian
Started: 02/08/2022
Status: Active
Attachments: 1 files
Logo Logo
Loading...