Impostazione Molteplici Flag

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

    Ciao a tutti,

    Devo inserire nel mio codice dei flag in modo da decidere se aprire o no una posizione.

    I flag non sono pochi, e così volevo chiedervi se le 2 versioni di codice che vi scrivo hanno lo stesso significato. Mi potete pf aiutare?

    //Codice 1
    indicatore1 = Average[100](close)
    Indicatore2 = Average[200](close)
    Condizione1 = (indicatore1 CROSSES OVER Indicatore2)
    Condizione2 = (Flag = 0)
    IF Condizione1 and Condizione2 THEN
    BUY 1 CONTRACTS AT MARKET
    ENDIF

    //Codice 2
    indicatore1 = Average[100](close)
    Indicatore2 = Average[200](close)
    Condizione1 = (indicatore1 CROSSES OVER Indicatore2)
    IF Condizione1 and Flag = 0 THEN
    BUY 1 CONTRACTS AT MARKET
    ENDIF

    #229111 quote
    GraHalGraHal
    Participant
    Master

    Sì, entrambe le versioni del codice produrranno lo stesso risultato.

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

Impostazione Molteplici Flag


ProOrder: Trading Automatico & Backtesting

New Reply
Author
author-avatar
MICH @mich Participant
Summary

This topic contains 1 reply,
has 2 voices, and was last updated by GraHalGraHal
2 years, 6 months ago.

Topic Details
Forum: ProOrder: Trading Automatico & Backtesting
Language: Italian
Started: 03/02/2024
Status: Active
Attachments: No files
ProRealCode ProRealCode
Loading...