conversion en MQL

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

    Bien le bonjour, étant IG, j’aimerais pouvoir utiliser un système de trading auto de ProRealTime sur la plate forme Metatrader. Est ce que il y aurait une âme charitable connaissant le langage MQL (4ou5) qui pourrait me faire une conversion de ce code assez simple (63 lignes)

    // ACCUMULATION D'ORDRE et PRE CHARGEMENT du Bot------------------------------------------------------------
    
    DEFPARAM CumulateOrders = false
    DEFPARAM Preloadbars = 3000
    
    // STRATEGY PROFITS-----------------------------------------------------------------------------------------
    
    IF init=not onmarket THEN
    step=0
    init=1
    ENDIF
    
    SL          = 138
    TP          = 185
    UNDERLAYING = 100
    REINV       = 1
    LotDeBase   = 1
    
    // INDICATEUR-----------------------------------------------------------------------------------------------
    
    condbuy = Volume > 700 and volume[1] < volume and time > 153000 and time < 210000 and open < close and average[75](close) > average[30](close)
    
    // POSITION ------------------------------------------------------------------------------------------------
    
    IF CONDbuy THEN
    buy LotDeBase contract at market
    ENDIF
    
    // TRAILING STOP CONDITION----------------------------------------------------------------------------------
    
    TGL0 = 65
    
    IF not onmarket THEN
    MAXPRICE = 0
    PRICEXIT = 0
    ENDIF
    
    IF longonmarket  THEN
    MAXPRICE = MAX(MAXPRICE,close)
    IF MAXPRICE - tradeprice(1) >= TGL0 * pointsize THEN
    PRICEXIT = MAXPRICE - TGL0 * pointsize
    ENDIF
    ENDIF
    
    IF onmarket and PRICEXIT>0 THEN
    SELL at PRICEXIT STOP
    ENDIF
    
    // STOP LOSS CONDITION--------------------------------------------------------------------------------------
    
    IF not onmarket THEN
    sloss = 0
    ELSIF longonmarket THEN
    sloss = tradeprice(1) - ((tradeprice(1) * SL) / underlaying) * pointsize
    ELSIF shortonmarket THEN
    sloss = tradeprice(1) + ((tradeprice(1) * SL) / underlaying) * pointsize
    ENDIF
    
    SET STOP pLOSS SL
    
    IF not onmarket THEN
    ptarget = 0
    ELSIF longonmarket THEN
    ptarget = tradeprice(1) + ((tradeprice(1) * TP) / underlaying) * pointsize
    ELSIF shortonmarket THEN
    ptarget = tradeprice(1) - ((tradeprice(1) * TP) / underlaying) * pointsize
    ENDIF
    
    SET TARGET pPROFIT TP
    
    // BREAKEVEN------------------------------------------------------------------------------------------------
    
    startBreakeven0 = 28
    PointsToKeep0   = 7
    
    IF NOT ONMARKET THEN
    breakevenLevel=0
    ENDIF
    
    // BE FOR LONG---------------------------------------------------------------------------------------------
    
    IF longonmarket and close - tradeprice(1) >= StartBreakeven0 * pipsize THEN
    BreakevenLevel = tradeprice(1) + PointsToKeep0 * pipsize
    ENDIF
    
    IF breakevenLevel>0 THEN
    sell AT breakevenLevel STOP
    ENDIF
    
    if longonmarket and close - tradeprice(1) >= 50*pipsize and step = 0 Then
    step = 1
    endif
    
    IF step = 1 THEN
    sell 0.1 contracts at market
    step = 2
    endif
    
    // END------------------------------------------------------------------------------------------------------

     

    . Ou si quelqu’un connait un endroit ou je pourrais y faire ma demande, merci d’avance.

    #204807 quote
    NicolasNicolas
    Keymaster
    Legend

    Désolé, nous ne proposons pas d’assistance gratuite pour utiliser d’autres plateformes 🙂

    Pour les demandes d’assistance privée (et payante), tu peux suivre ce lien: https://www.prorealcode.com/trading-programming-services/

    #204808 quote
    EzelEzel
    Participant
    New

    merci bien

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

conversion en MQL


ProOrder : Trading Automatique & Backtests

New Reply
Author
author-avatar
Ezel @ezel Participant
Summary

This topic contains 2 replies,
has 2 voices, and was last updated by EzelEzel
3 years, 10 months ago.

Topic Details
Forum: ProOrder : Trading Automatique & Backtests
Language: French
Started: 11/25/2022
Status: Active
Attachments: No files
ProRealCode ProRealCode
Loading...