Gap schließen bei aktien

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #207849 quote
    axmichiaxmichi
    Participant
    Senior

    Hallo,

    ich suche einen Code für eine Gap Strategie die short geht, wenn das Open mehr als 6 Punkte  über dem Hoch des vergangenen Tages liegt.

    Das target liegt auf dem Hoch des vergangene Tages und der Stop ist die Spanne von Hoch zum Open also 1:1

    Timeframe ist 5 minutenchart und es soll nur einen Trade am Tag geben

     

    Vielen Danke

    #208075 quote
    robertogozzirobertogozzi
    Moderator
    Legend

    Da ist er:

    DEFPARAM CumulateOrders = false
    OTD = Barindex - TradeIndex(1) > IntradayBarIndex    //limits the trades to 1 per day (OTD One Trade per Day)
    Gap = Dopen(0) > (Dhigh(1) + 6 * PipSize)
    IF Gap AND OTD THEN
       SELLSHORT 1 Contract at Market
       SET TARGET Profit abs(close - Dhigh(1))
       SET STOP   Loss   abs(close - Dhigh(1))
    ENDIF
    #209272 quote
    axmichiaxmichi
    Participant
    Senior

    Hallo,

     

    bei meinen GAP in Long Richtung soll der SL auf dem Hoch des letzten Tages liegen.

    Leider wird der Trade nicht ausgestoppt, der stop funktioniert nicht. was ist hier falsch:  siehe Bild

     

    SL = DHigh(1) //abs(close +
    SET STOP Loss SL

    graphonprice SL coloured(255,0,0,255)AS “StopLoss”

    SL-frage.png SL-frage.png
    #209300 quote
    robertogozzirobertogozzi
    Moderator
    Legend

    Weil SET STOP LOSS und SET TARGET PROFIT (und ihre Varianten) einen DIFFERENCE zwischen den Preisen erfordern, keinen Preis, sonst haben Sie einen SL von 15000 Punkten!
    In Ihrem Fall lautet die Anweisung:

    SET STOP Price SL
    #209464 quote
    axmichiaxmichi
    Participant
    Senior

    Vielen Dank!!

Viewing 5 posts - 1 through 5 (of 5 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

Gap schließen bei aktien


ProOrder: Automatischer Handel & Backtesting

New Reply
Author
author-avatar
axmichi @axmichi Participant
Summary

This topic contains 4 replies,
has 2 voices, and was last updated by axmichiaxmichi
3 years, 7 months ago.

Topic Details
Forum: ProOrder: Automatischer Handel & Backtesting
Language: German
Started: 01/22/2023
Status: Active
Attachments: 1 files
ProRealCode ProRealCode
Loading...