Are they the same? crosses over between 2 values

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

    Hi, May i ask if the A and B are the same?

    A

    c2 = (indicator1[1] crosses over indicator2[1]) or (indicator1[2] crosses over indicator2[2])

    <hr />

    B

    c1 = (indicator1 crosses over indicator2)

    c2 = c1[1] or c1[2]

    thanks

    #205520 quote
    GraHal
    Participant
    Master

    Do you get the same result with A and B when testing (A only, then B only) as part of an Auto-System?

    If No, then A is not the same as B.

    PeterSt thanked this post
    #205543 quote
    JS
    Participant
    Senior

    Hi @WingYip

    With a simple test you can see that A and B give the same result…

     
    S1=Average[20](Close)
    S2=Average[50](close)
    
    If S1[1] Crosses Over S2[1] or S1[2] Crosses Over S2[2] then
    DrawArrowUp(BarIndex, S1+50) Coloured(255,0,0)
    EndIf
    
    C1 = S1 Crosses Over S2
    
    If C1[1] or C1[2] then
    DrawArrowDown(BarIndex, S1-50)Coloured(0,255,0)
    EndIf
    Return
    GraHal and Midlanddave thanked this post
Viewing 3 posts - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.

Are they the same? crosses over between 2 values


ProOrder: Automated Strategies & Backtesting

New Reply
Author
author-avatar
Marco @wingyip Participant
Summary

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

Topic Details
Forum: ProOrder: Automated Strategies & Backtesting
Language: English
Started: 12/09/2022
Status: Active
Attachments: No files
Logo Logo
Loading...