stop in pari

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #197561 quote
    cimsalcimsal
    Participant
    Junior

    gentilmente come posso aggiungere ad un mio sistema uno stop in pari o in gain di 1 punto, grazie

    #197572 quote
    robertogozzirobertogozzi
    Moderator
    Legend

    Per mettere lo SL in pari scrivi:

    Set Stop Breakeven

    Per metterlo ad 1 punto oltre il prezzo d’entrata:

    Set Stop Price (TRADEPRICE + 1*PipSize)
    #197598 quote
    cimsalcimsal
    Participant
    Junior

    grazie, a che punto mettere la riga, di nuovo grazie

    #197602 quote
    robertogozzirobertogozzi
    Moderator
    Legend

    Dipende da come è strutturato il tuo codice; immagino che vorrai metterlo quando c’è un certo profitto.

    Esempio:

    Profitto = PositionPrice * PositionPerf / PipSize
    If Profitto > X then
       Set Stop Breakeven
    Endif

    X è il numero pips dopo i quali mettere lo stop loss in pareggio.

    #197660 quote
    cimsalcimsal
    Participant
    Junior

    scusi ma non mi funziona

    #197708 quote
    robertogozzirobertogozzi
    Moderator
    Legend

    A me funziona correttamente:

    if close crosses over average[100] then
       buy at market
    elsif close crosses under average[100] then
       sellshort at market
    endif
    set target pprofit 300
    set stop   ploss   100
    Profitto = PositionPrice * PositionPerf / PipSize
    If Profitto > 50 then
       Set Stop Breakeven
    Endif
    graphonprice PositionPrice
    graph positionprice * positionperf / pipsize AS "Pips"
Viewing 6 posts - 1 through 6 (of 6 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 in pari


ProOrder: Trading Automatico & Backtesting

New Reply
Author
author-avatar
cimsal @cimsal Participant
Summary

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

Topic Details
Forum: ProOrder: Trading Automatico & Backtesting
Language: Italian
Started: 07/20/2022
Status: Active
Attachments: No files
ProRealCode ProRealCode
Loading...