orario di negozziazione

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

    Buonasera, avrei bisogno di inserire un intervallo di orario per poter operare, le operazioni possono entrare a mercato dalle 00:30 alle 05:00 e poi dalle 07:00 alle 23:00, naturalmente le operazioni aperte prima delle 5 non devono essere chiuse alle 5 ma solo rispettando gli stop loss oppure take profit. come posso scrivere questo parte del codice?

    #189922 quote
    MauroProMauroPro
    Participant
    Veteran

    cTime = (time >= 003000 and time <= 050000) or (time >= 070000 and time <= 230000)

    #189923 quote
    emanuele81emanuele81
    Participant
    Senior

    grazie mille Mauro

    #189925 quote
    MauroProMauroPro
    Participant
    Veteran

    Nel caso volessi chiudere le operazioni aperte in quegli orari non con SL\TP ma, ad esempio, alle ore 5 devi aggiungere al codice :

    if time = 050000 then

    sell at market

    exitShort at market

    endif

    #189926 quote
    robertogozzirobertogozzi
    Moderator
    Legend

    Esatto.

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

orario di negozziazione


ProOrder: Trading Automatico & Backtesting

New Reply
Author
author-avatar
emanuele81 @emanuele81 Participant
Summary

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

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