stop dinamici valori diversi

Viewing 2 posts - 16 through 17 (of 17 total)
  • Author
    Posts
  • #182747 quote
    leo di mennoleo di menno
    Participant
    Average

    sono impantanato su di una cosa stupida, vorrei dire alla macchina di associare allo stop loss il valore di ingresso + x*pipsize, ho provato questo

    if shortonmarket then
    stoploss =open[1] + AverageTrueRange[14](close)
    newsl = stoploss

    però cosi il valore mi cambia man mano che le candele si susseguono

    #182769 quote
    robertogozzirobertogozzi
    Moderator
    Legend

    Certo, non devi metterlo li, ma all’interno dell’IF che fa l’entrata:

    if MieCondizioniShort and Not ShortOnMarket then
       stoploss =open[1] + AverageTrueRange[14](close)
       newsl = stoploss
       Sellshort 1 Contract at Market
    Endif

    in questo modo esegue quell’istruzione solo la prima volta.

Viewing 2 posts - 16 through 17 (of 17 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

stop dinamici valori diversi


ProOrder: Trading Automatico & Backtesting

New Reply
Author
Summary

This topic contains 16 replies,
has 2 voices, and was last updated by robertogozzirobertogozzi
4 years, 10 months ago.

Topic Details
Forum: ProOrder: Trading Automatico & Backtesting
Language: Italian
Started: 08/23/2021
Status: Active
Attachments: 4 files
ProRealCode ProRealCode
Loading...