Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Simple Strategy Problem ...

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Simple Strategy Problem ...

    I'm trying (and trying and trying ...) to implement a very simple strategy using a custom indicator called the Trix 2 (plots perfectly on the chart, no issues with the indicator itself -- has 3 lines, Trix Line 1 and 2 signal lines) and I'm running into issues. I want to go long when the Trix Line 1 (the 3.75 value) upticks on bar close and reverse position to a short when it downticks, ignoring the two signal lines entirely within the Trix 2 indicator. Only one other parameter: go long only if Trix Line 1 is below the .25 level and go short only if the Trix Line 1 is above the -.25 level. Really simple.
    Attached is the code I thought should do the trick -- it generates a large number of incorrect entry points and very few correct ones. Been working on this for many, many days so any help would be greatly appreciated --david
    Attached Files

    #2
    TakingStock12, I would suggest simplify as much as possible and then add visuals to check into what signals are really triggering as per your rules (like drawing arrows for example), this way you know what works as you expect and what needed further tweaks. For example you just check for < > a value, this will stay 'true' and not only trigger if there's a real crossover signal, so you likely get way more signals because of this aspect.

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by Geovanny Suaza, 02-11-2026, 06:32 PM
    0 responses
    649 views
    0 likes
    Last Post Geovanny Suaza  
    Started by Geovanny Suaza, 02-11-2026, 05:51 PM
    0 responses
    370 views
    1 like
    Last Post Geovanny Suaza  
    Started by Mindset, 02-09-2026, 11:44 AM
    0 responses
    109 views
    0 likes
    Last Post Mindset
    by Mindset
     
    Started by Geovanny Suaza, 02-02-2026, 12:30 PM
    0 responses
    574 views
    1 like
    Last Post Geovanny Suaza  
    Started by RFrosty, 01-28-2026, 06:49 PM
    0 responses
    576 views
    1 like
    Last Post RFrosty
    by RFrosty
     
    Working...
    X