Aggiungere un avviso / allarme

Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
    Posts
  • #67406 quote
    Gianco
    Participant
    Senior

    Buongiorno a tutti , posso gentilmente chiedere come si può correggere un indicatore nel momento in cui si forma una freccia dia anche un avviso del tipo : Acustico tipo allarme? , oppure usando una finestra del tipo ProScreener ? Vi allego il file a cui vorrei apporre questa aggiunta ,      Grazie

    DEFPARAM CalculateOnLastBars = 1000
    
    //text color
    // white = 255,255,255 ; black = 0,0,0
    
    //atr = averagetruerange[10](close)*0.5 //offset per il display di frecce e nomi sul grafico dei prezzi
    
    x = 0
    
    DojiSize = 0.05
    data=(abs(open – close) <= (high – low) * DojiSize)
    if data then
    x = 1
    r = 127
    g = 255
    b = 212
    //DRAWTEXT(“Doji”, barindex, high+atr, Dialog, Standard, 12) COLOURED(R,G,B) Azzurro
    endif
    
    data2=(close[2] > open[2] and min(open[1], close[1]) > close[2] and open < min(open[1], close[1]) and close < open )
    if data2 then
    x = 3
    r = 255
    g = 0
    b = 0
    //DRAWTEXT(“Evening Star”, barindex, high[1]+atr*1.5, Dialog, Standard, 12) COLOURED(255,0,10) Rosso
    //DRAWARROWDOWN(barindex-1,high[1]) COLOURED(255,0,10)
    endif
    
    data3=(close[2] < open[2] and max(open[1], close[1]) < close[2] and open > max(open[1], close[1]) and close > open )
    if data3 then
    x = 3
    r = 165
    g = 42
    b = 42
    //DRAWTEXT(“Morning Star”, barindex, low[1]-atr*1.5, Dialog, Standard, 12) COLOURED(0,255,10) Moro
    //DRAWARROWUP(barindex-1,low[1]) COLOURED(0,255,10)
    endif
    
    data4=(open[1] < close[1] and open > close[1] and high – max(open, close) >= abs(open – close) * 3 and min(close, open) – low <= abs(open – close))
    if data4 then
    x = 1
    r = 222
    g = 184
    b = 135
    //DRAWTEXT(“Shooting Star”, barindex, high+atr*1.5, Dialog, Standard, 12) COLOURED(255,0,10) Nocciola
    //DRAWARROWDOWN(barindex,high) COLOURED(255,0,10)
    endif
    
    data5=(((high – low)>3*(open -close)) and ((close – low)/(.001 + high – low) > 0.6) and ((open – low)/(.001 + high – low) > 0.6))
    if data5 then
    x = 1
    r = 95
    g = 158
    b = 160
    //DRAWTEXT(“Hammer”, barindex, high+atr, Dialog, Standard, 12) COLOURED(R,G,B) Avio Scuro
    endif
    
    data5b=(((high – low)>3*(open -close)) and ((high – close)/(.001 + high – low) > 0.6) and ((high – open)/(.001 + high – low) > 0.6))
    if data5b then
    x = 4
    r = 255
    g = 255
    b = 0
    //DRAWTEXT(“Inverted Hammer”, barindex, high+atr, Dialog, Standard, 12) COLOURED(R,G,B) Giallo
    endif
    
    data6=(close[1] > open[1] and open > close and open <= close[1] and open[1] <= close and open – close < close[1] – open[1] )
    if data6 then
    x = 1
    r = 255
    g = 127
    b = 80
    //DRAWTEXT(“Bearish Harami”, barindex, high+atr*1.5, Dialog, Standard, 12) COLOURED(255,0,10)marrone chiaro
    //DRAWARROWDOWN(barindex,high) COLOURED(255,0,10)(NOCCIOLA)
    endif
    
    data7=(open[1] > close[1] and close > open and close <= open[1] and close[1] <= open and close – open < open[1] – close[1] )
    if data7 then
    x = 1
    r = 169
    g = 169
    b = 169
    //DRAWTEXT(“Bullish Harami”, barindex, low-atr*1.5, Dialog, Standard, 12) COLOURED(0,255,10) Grigio chiaro
    //DRAWARROWUP(barindex,low) COLOURED(0,255,10)(GRIGIO)
    endif
    
    data8=(close[1] > open[1] and open > close and open >= close[1] and open[1] >= close and open – close > close[1] – open[1] )
    if data8 then
    x = 3
    r = 34
    g = 139
    b = 34
    //DRAWTEXT(“Bearish Engulfing”, barindex, high+atr*1.5, Dialog, Standard, 12) COLOURED(255,0,10) Verde
    //DRAWARROWDOWN(barindex,high) COLOURED(255,0,10)(VERDE)
    endif
    
    data9=(open[1] > close[1] and close > open and close >= open[1] and close[1] >= open and close – open > open[1] – close[1] )
    if data9 then
    x = 1
    r = 255
    g = 0
    b = 255
    //DRAWTEXT(“Bullish Engulfing”, barindex, low-atr*1.5, Dialog, Standard, 12) COLOURED(0,255,10)Fuxia scuro
    //DRAWARROWUP(barindex,low) COLOURED(0,255,10)(FUXIA)
    endif
    
    data10=(close[1] < open[1] and open < low[1] and close > close[1] + ((open[1] – close[1])/2) and close < open[1])
    if data10 then
    x = 1
    r = 127
    g = 255
    b = 0
    //DRAWT0EXT(“Piercing Line”, barindex, low-atr*1.5, Dialog, Standard, 12) COLOURED(0,255,10) Verde chiaro
    //DRAWARROWUP(barindex,low) COLOURED(0,255,10)
    endif
    
    data14=(((high-low>4*(open-close))and((close-low)/(.001+high-low)>=0.75)and((open-low)/(.001+high-low)>=0.75)) and high[1] < open and high[2] < open)
    if data14 then
    x = 1
    r = 128
    g = 128
    b = 128
    //DRAWTEXT(“Hanging Man”, barindex, high+atr*1.5, Dialog, Standard, 12) COLOURED(255,0,10)Grigio scuro
    //DRAWARROWDOWN(barindex,high) COLOURED(255,0,10)
    endif
    
    data15=((close[1]>open[1])and(((close[1]+open[1])/2)>close)and(open>close)and(open>close[1])and(close>open[1])and((open-close)/(.001+(high-low))>0.6))
    if data15 then
    x = 1
    r = 238
    g = 130
    b = 238
    //DRAWTEXT(“Dark Cloud Cover”, barindex, high+atr*1.5, Dialog, Standard, 12) COLOURED(255,0,10)Fuxia Chiaro
    //DRAWARROWDOWN(barindex,high) COLOURED(255,0,10)
    endif
    
    RETURN x COLOURED(r,g,b) STYLE(histogram,1)

     

     

    Gianluigi

    #67415 quote
    Nicolas
    Keymaster
    Master

     Suggerimento: quando pubblichi in questo forum, segui queste semplici regole:

    • Per scrivere il codice , utilizza il pulsante <> “insert PRT code”.
    #67423 quote
    Gianco
    Participant
    Senior
    // The Hikkake Pattern, by Daniel Chesler, CMT
    // The 'Fakey' entry
    // coded by Violet
    // 28-11-2017
    //
    
    // For an explanation of the pattern, consult this webpage:
    // http://www.esignallearning.com/education/marketmaster/archive/2012/archive_index.aspx?date=041312
    // Also read this interesting report:
    // https://oxfordstrat.com/trading-strategies/hikkake-pattern/
    //
    // Use it for market timing, but always in conjunction with position sizing and a sensible stoploss !
    // because like every other technique this one may fail
    
    InsideBar = high[1] < high[2] and low[1] > low[2]
    FakeBullBar = low < low[1] and high < high[1]
    FakeBearBar = low > low[1] and high > high[1]
    
    // Long Setup
    if InsideBar and FakeBullBar then
    HikkakeBull = 1 // flag for a potential bullish setup
    InsideBullBarHigh = high[1] // set the high of the insidebar
    InsideBarNumber = barindex - 1
    HikkakeBarNumber = barindex // signal bar, bar number of completed Hikkake setup
    endif
    if HikkakeBull then
    WithinTimeLimit = (barindex - HikkakeBarNumber) <= 3
    if close > InsideBullBarHigh and WithinTimeLimit then
    //setup confirmed if price closes higher then InsideBullBarHigh within 3 bars after pattern completion
    drawarrowup(barindex,low-range/8) coloured(0,255,125)
    drawsegment(InsidebarNumber,InsideBullBarHigh+ticksize,barindex,InsideBullBarHigh+ticksize)
    drawtext("▴",barindex,InsideBullBarHigh-ticksize, dialog,bold,20)
    HikkakeBull = 0 // reset pattern detection flag
    endif
    endif
    
    // Short/Sell setup
    if InsideBar and FakeBearBar then
    HikkakeBear = 1 // flag for a potential bearish setup
    InsideBearBarLow = low[1] // set the low of the insidebar
    InsideBearBarNumber = barindex - 1
    HikkakeBearBarNumber = barindex // signal bar, bar number of completed Hikkake setup on third bar
    endif
    if HikkakeBear then
    WithinTimeLimit = (barindex - HikkakeBearBarNumber) <= 3
    if close < InsideBearBarLow and WithinTimeLimit then
    //setup confirmed if price closes lower then InsideBearBarow within 3 bars after pattern completion
    drawarrowdown(barindex,high+range/8) coloured(255,0,0)
    drawsegment(InsideBearBarNumber,InsideBearBarLow-ticksize,barindex,InsideBearBarLow-ticksize)
    drawtext("▾",barindex,InsideBearBarLow - ticksize, dialog,bold,20)
    HikkakeBear = 0 // reset pattern detection flag
    endif
    endif
    
    //drawcandle(open, high, low,close)
    
    return
    
    #67427 quote
    robertogozzi
    Moderator
    Master

    Non è possibile inserire allarmi da ProBuilder, solo col trading manuale PRT consente l’iunserimento di allarmi visivi (pop up) e sonori.

    #67544 quote
    Gianco
    Participant
    Senior

    Grazie Roberto , quindi non si riesce in qualche modo , quando nasce una freccia di indicazione , aggiungere una riga che faccia comparire una finestra di avviso ?

    #67545 quote
    Gianco
    Participant
    Senior

    Perchè se crei un automatismo di ProOrder , la finestra di ProScreen ti avvisa no ? Non si riesce così ?

    #67552 quote
    robertogozzi
    Moderator
    Master

    ProOrder non può interagire con ProScreener e neppure creare allarmi.

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

Aggiungere un avviso / allarme


ProBuilder: Indicatori & Strumenti Personalizzati

New Reply
Author
author-avatar
Gianco @gianco Participant
Summary

This topic contains 6 replies,
has 3 voices, and was last updated by robertogozzi
7 years, 11 months ago.

Topic Details
Forum: ProBuilder: Indicatori & Strumenti Personalizzati
Language: Italian
Started: 04/06/2018
Status: Active
Attachments: No files
Logo Logo
Loading...