Anchored VWAP scripts

Optuma Forums Optuma Scripting Anchored VWAP scripts

  • This topic has 3 replies, 2 voices, and was last updated 2 weeks ago by Marc.
Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
  • #57277
    • Topics: 73
    • Replies: 937
    • Posts: 1,010

    To calculate the distance from the anchored VWAP line for IPOs – and therefore be alerted when the level is crossed – use the following scripts.

    [Click here and here for other IPO posts.]

    Distance from A-VWAP as a Show View tool or watchlist column:

    The following can be added to a watchlist for A-VWAP crosses:

    This shows PTON crossing below, and WORK above:


    To format the A-VWAP Cross column right-click on the header and change the Custom Labels to match the values in the script (ie ==1 is Above, etc):


    • Topics: 23
    • Replies: 38
    • Posts: 61

    Hi Optuma,

    I use the IPOVwap with standard deviations. Below is my script.

    Optuma limits the number of sigma multiplier to 4 which does not allow to cover every charts (check Apple, Nvidia)  Would it be possible to raise this limit? (this issue was already raised here and left unanswered).

    (I also believe I could not put all the STD I wanted into the same script. I use another script to cover negative STD + 50% of the third upward channel).


    // IPOvwap

    //IPOvwap_STD_down=STD(IPOvwap, MULT=0.50, BARS=100, TYPE=Average Plus Deviation);

    IPOvwap_STD_up1=STD(IPOvwap, MULT=2.00, TYPE=Average Plus Deviation);
    IPOvwap_STD_up2=STD(IPOvwap, MULT=3.00, BARS=100, TYPE=Average Plus Deviation);
    IPOvwap_STD_upx3=STD(IPOvwap, MULT=4.00, BARS=100, TYPE=Average Plus Deviation);

    IPOvwap_STD_upx1.5=STD(IPOvwap, MULT=1.50, BARS=100, TYPE=Average Plus Deviation);
    IPOvwap_STD_upx2.5=STD(IPOvwap, MULT=2.50, BARS=100, TYPE=Average Plus Deviation);
    IPOvwap_STD_upx3.5=STD(IPOvwap, MULT=3.50, TYPE=Average Plus Deviation, BARS=100);

    plot0= IPOvwap;

    plot2 = IPOvwap_STD_up1;
    plot3 = IPOvwap_STD_up2;
    plot4 = IPOvwap_STD_upx3;

    //50% up
    plot5 = IPOvwap_STD_upx1.5;
    plot6 = IPOvwap_STD_upx2.5;
    plot7 = IPOvwap_STD_upx3.5;

    plot0.Colour = yellow;
    plot0.Linestyle = dot;
    plot0.LineWidth = 2;
    plot1.Colour = red;
    plot1.LineWidth = 2;
    plot2.Colour = red;
    plot2.LineWidth = 2;
    plot3.Colour = red;
    plot3.LineWidth = 2;
    plot3.transparency = 100;
    plot4.Colour = red;
    plot4.Colour = red;
    plot4.LineWidth = 2;
    plot4.transparency = 100;
    plot5.Colour = red;
    plot5.Colour = red;
    plot5.LineWidth = 1;
    plot5.transparency = 20;
    plot5.Colour = red;
    plot6.LineWidth = 1;
    plot6.transparency = 20;
    plot6.Colour = red;
    plot7.Colour = red;
    plot7.LineWidth = 1;
    plot7.transparency = 20;

    • Topics: 73
    • Replies: 937
    • Posts: 1,010

    Hi Marc,

    Sigma is a statistical measure on normal distributions, so I don’t think it makes sense to have higher sigmas (4 sigmas will include 99.9937% of expected events which is why there’s a limit). Instead, you could multiply the original STD calculation to get the different levels, which is what we made available in the Linear Regression Bands tool in response to the other post.

    Here’s how that looks on NVDA:


    • Topics: 23
    • Replies: 38
    • Posts: 61

    Excellent. Thanks Darren

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.

Pin It on Pinterest