Stop Loss al mínimo de 5 velas y Benef al doble del Stop

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #175723 quote
    DALUPEZDALUPEZ
    Participant
    New

    Estimados: Quiero hacer un Backtest de una estrategia, y quiero colocar un stop loss por dejajo del mínimo de las últimas 5 velas diarias, y el target profit (Objetivo de Beneficios) al doble del % de stop determinado. Para que la relación riesgo retorno sea 2:1. Es decir, supungamos que el Stop sea 5%, el Target debería ser el 10%. ¿Alguien me podría ayudar?

    #175728 quote
    robertogozzirobertogozzi
    Moderator
    Legend

    Ahi esta:

    MyLongConditions = close CROSSES OVER average[10,0](close)
    IF MyLongConditions AND Not OnMarket THEN
       BUY 1 Contract at Market
       Sl = close - lowest[5](low)
       Tp = Sl * 2
       SET TARGET PROFIT Tp
       SET STOP   LOSS   Sl
    ENDIF
    #175739 quote
    DALUPEZDALUPEZ
    Participant
    New

    Muchas gracias, Una última consulta. ¿Para poner un stop loss debajo de la MM50 al momento de la compra por ejemplo como sería? Desde ya muchas gracias

Viewing 3 posts - 1 through 3 (of 3 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 Loss al mínimo de 5 velas y Benef al doble del Stop


ProOrder: Trading Automático y Backtesting

New Reply
Author
author-avatar
DALUPEZ @dalupez Participant
Summary

This topic contains 2 replies,
has 2 voices, and was last updated by DALUPEZDALUPEZ
5 years, 1 month ago.

Topic Details
Forum: ProOrder: Trading Automático y Backtesting
Language: Spanish
Started: 08/19/2021
Status: Active
Attachments: No files
ProRealCode ProRealCode
Loading...