Is it possible to use Zero Lag Exponential in the code

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #9236 quote
    jannetajanneta
    Participant
    New

    Hi Guys,

    Is it possible to use Zero Lag Exponential Bollinger in the code ?
    As far I see I can’t use Zero Lag Exponential Bollinger Up or down bands even they are displayed live on chart together with price. Is it possible to use it somehow in the code ?

    Thanks for any help,
    Janneta

    #9244 quote
    NicolasNicolas
    Keymaster
    Legend

    Hi janneta,

    Yes it would be possible, but it needs to recode a complete bollinger bands indicator made of Zerolag EMA for that.

    Here is the code I just wrote for this:

    // parameters
    // period = 20
    // dev = 2.0
    
    lag = ROUND((period-1)/2)
    data = (close + (close-close[lag]))
    
    ZLEMA = exponentialaverage[period](data)
    BolUp = ZLEMA+STD[period]*dev
    BolDn = ZLEMA-STD[period]*dev
    
    RETURN ZLEMA as "ZeroLag EMA", BolUp as "Bollinger Up ZLEMA", BolDn as "Bollinger Down ZLEMA"

    Please find attached the file and a screenshot.

    zerolag-bollinger-bands.png zerolag-bollinger-bands.png
Viewing 2 posts - 1 through 2 (of 2 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

Is it possible to use Zero Lag Exponential in the code


ProBuilder: Indicators & Custom Tools

New Reply
Author
author-avatar
janneta @janneta Participant
Summary

This topic contains 1 reply,
has 2 voices, and was last updated by NicolasNicolas
10 years, 3 months ago.

Topic Details
Forum: ProBuilder: Indicators & Custom Tools
Language: English
Started: 06/11/2016
Status: Active
Attachments: No files
ProRealCode ProRealCode
Loading...