DayOfWeek / Trading from Tuesday to Friday

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #22710 quote
    RoLaDayRoLaDay
    Participant
    Average

    Hello everybody,

    I wonder how I can trade from Tuesday to Friday.

    I only found out how to trade e.g. on Tuesday (dayofweek= 2) but not how to trade from Tuesday – Friday.

    Thanks a lot!

    #22719 quote
    4everTrading4everTrading
    Participant
    Senior

    Hello there

    I think the best option the choose the days you’d like to trade it should be something like this.

    Regards

    #Haveagoodweekend

    
    
    if dayofweek=1 then //Monday
    daytrading=0
    endif
    if dayofweek=2 then // Tuesday
    daytrading=1
    endif
    if dayofweek=3 then // Wednesday
    daytrading=1
    endif
    if dayofweek=4 then //Thursday
    daytrading=1
    endif
    if dayofweek=5 then // Friday
    daytrading=1
    endif
    
    // In the condition makes reference to the dayofweek=x
    IF  daytrading= 1  AND "condition2" THEN
     ......
    ENDIF
    
    #22723 quote
    RoLaDayRoLaDay
    Participant
    Average

    Works great! Thanks a lot and have a nice weekend too šŸ™‚

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

DayOfWeek / Trading from Tuesday to Friday


ProOrder: Automated Strategies & Backtesting

New Reply
Author
author-avatar
RoLaDay @roladay Participant
Summary

This topic contains 2 replies,
has 2 voices, and was last updated by RoLaDayRoLaDay
9 years, 9 months ago.

Topic Details
Forum: ProOrder: Automated Strategies & Backtesting
Language: English
Started: 01/27/2017
Status: Active
Attachments: No files
ProRealCode ProRealCode
Loading...