Volume Candele – Toro/Orso

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #208779 quote
    byT77
    Participant
    New

    Gent.mo Roberto,

    Necessito codificare in codice, una variante.

    Vorrei sapere, nelle ultime dieci candele, la somma dei volumi di quelle rialziste(quindi con chiusura > open) e di quelle ribassiste(quindi con chiusura < open).

    Grazie in anticipo

    #208854 quote
    Nicolas
    Keymaster
    Master

    Il codice seguente traccia 2 righe che rappresentano la somma dei volumi delle candele ribassiste o rialziste nell'ultimo periodo (è possibile modificare il periodo desiderato nella prima riga del codice).

    period = 10
    
    sumbullish=0
    sumbearish=0
    for i = 0 to period-1 do 
    if close[i]>open[i] then 
    sumbullish=sumbullish+volume[i]
    else
    sumbearish=sumbearish+volume[i]
    endif 
    next
    
    return sumbullish coloured("green"), sumbearish coloured("red")
    bullish-and-bearish-volumes-oscillator.png bullish-and-bearish-volumes-oscillator.png
    #208859 quote
    byT77
    Participant
    New

    Grazie Roberto.

    Gentilissimo come sempre.

    Buon proseguimento

    #208881 quote
    robertogozzi
    Moderator
    Master

    Non ero io (sono in vacanza fino al 16), ma Nicolas 🙂

    #208884 quote
    byT77
    Participant
    New

    Chiedo venia.

    Grazie comunque. Sempre gentili

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

Volume Candele – Toro/Orso


ProBuilder: Indicatori & Strumenti Personalizzati

New Reply
Author
author-avatar
byT77 @byt77 Participant
Summary

This topic contains 4 replies,
has 3 voices, and was last updated by byT77
3 years, 1 month ago.

Topic Details
Forum: ProBuilder: Indicatori & Strumenti Personalizzati
Language: Italian
Started: 01/30/2023
Status: Active
Attachments: 1 files
Logo Logo
Loading...