Anchored VWAP High and Low

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #188565 quote
    JackDJackD
    Participant
    Junior

    Hi,

    Would it be possible to get a Anchored VWAP indicator for the daily high and the daily low? There is one on Tradingview but I cant seem to find anything close on PRT

    Cheers,

    Jack

    #188593 quote
    NicolasNicolas
    Keymaster
    Legend

    The below code will compute and plot in real time the VWAP anchored on both daily high and daily low:

    if dhigh(0)>dhigh(0)[1] then 
    starthigh=barindex
    endif
    if dlow(0)<dlow(0)[1] then 
    startlow=barindex
    endif 
    
    dh = max(1, barindex-starthigh)
    dl = max(1, barindex-startlow)
    
    VWAPh = SUMMATION[dh](volume*typicalprice)/SUMMATION[dh](volume)
    VWAPl = SUMMATION[dl](volume*typicalprice)/SUMMATION[dl](volume)
    
    
    RETURN VWAPh coloured("red"), vwapl coloured("green")
    #188688 quote
    JackDJackD
    Participant
    Junior

    Great thank you so much!!! šŸ™‚

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

Stuck on this ProBuilder code?

Describe what this topic is trying to build, in plain English, and ProRealAI writes the ProRealTimeā„¢ indicator, screener or system for you.

Available in 7 languages
Try ProRealAI

Anchored VWAP High and Low


ProBuilder: Indicators & Custom Tools

New Reply
Author
author-avatar
JackD @jackd Participant
Summary

This topic contains 2 replies,
has 2 voices, and was last updated by JackDJackD
4 years, 7 months ago.

Topic Details
Forum: ProBuilder: Indicators & Custom Tools
Language: English
Started: 02/20/2022
Status: Active
Attachments: No files
ProRealCode ProRealCode
Loading...