vorrei uno screener che che mi avvisa dei cambi di colore del supertrend grazie

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #246155 quote
    ACHILLE2ACHILLE2
    Participant
    Junior

    vorrei uno screener che che mi avvisa dei cambi di colore del supertrend grazie

    #246204 quote
    Iván GonzálezIván González
    Moderator
    Legend

    ecco:

    //------------------------------------------//
    //PRC_SuperTrend
    //www.prorealcode.com
    //Sharing ProRealTime knowledge
    //------------------------------------------//
    //-----Inputs-------------------------------//
    //------------------------------------------//
    periods = 10 //ATR period
    multiplier = 3 //ATR multiplier
    //------------------------------------------//
    //----SuperTrend Calculation----------------//
    //------------------------------------------//
    atr = averagetruerange[periods](close)
    up = high - multiplier*atr
    up1 = up[1]
    if close[1] > up1 then
    up = max(up,up1)
    else
    up = up
    endif
    
    dn = low + multiplier*atr
    dn1 = dn[1]
    if close[1] < dn1 then
    dn = min(dn,dn1)
    else
    dn = dn
    endif
    
    once trend = 1
    
    if trend = -1 and close > dn1 then
    trend = 1
    elsif trend = 1 and close < up1 then
    trend = -1
    else
    trend = trend
    endif
    //------------------------------------------//
    //----Buy and Sell Signals------------------//
    //------------------------------------------//
    buysignal = trend=1 and trend[1]=-1
    sellsignal = trend=-1 and trend[1]=1
    
    screener[buysignal or sellsignal](buysignal as "Buy",sellsignal as "Sell")
    
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

vorrei uno screener che che mi avvisa dei cambi di colore del supertrend grazie


ProScreener: Scansione Mercati & Screener

New Reply
Author
author-avatar
ACHILLE2 @achille2 Participant
Summary

This topic contains 1 reply,
has 2 voices, and was last updated by Iván GonzálezIván González
1 year, 4 months ago.

Topic Details
Forum: ProScreener: Scansione Mercati & Screener
Language: Italian
Started: 04/21/2025
Status: Active
Attachments: No files
ProRealCode ProRealCode
Loading...