Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Stochastic Entry

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

    Stochastic Entry

    I am trying to get enter a trade when the ema crosses the median but only if the stochastic is above 80, rather than an exact crossover. Can someone help me adjust this code.

    // Condition set 1
    if (CrossBelow(HawkmatixMovingAverage(21), HawkmatixMovingMedian(25), 1))
    if ((CrossBelow(Stochastics(Closes[0],1, 14, 4).K, Stochastics(Closes[0],2, 14, 4).D, 1)))

    #2
    mccallum28, you can check then for the K or D value to be greater than your treshhold value -

    if (your ema cross condition && Stochastics(Closes[0],1, 14, 4).K[0] > 80.0)

    Comment


      #3
      if(
      EMA(P)[1] < HawkmatixMovingMedian(P)[1] &&
      EMA(P)[0] > HawkmatixMovingMedian(P)[0] &&
      Stochastics(Closes[0],2, 14, 4).D[0] > 80 )
      EnterLong();
      fx.practic
      NinjaTrader Ecosystem Vendor - fx.practic

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by Geovanny Suaza, 02-11-2026, 06:32 PM
      0 responses
      599 views
      0 likes
      Last Post Geovanny Suaza  
      Started by Geovanny Suaza, 02-11-2026, 05:51 PM
      0 responses
      344 views
      1 like
      Last Post Geovanny Suaza  
      Started by Mindset, 02-09-2026, 11:44 AM
      0 responses
      103 views
      0 likes
      Last Post Mindset
      by Mindset
       
      Started by Geovanny Suaza, 02-02-2026, 12:30 PM
      0 responses
      558 views
      1 like
      Last Post Geovanny Suaza  
      Started by RFrosty, 01-28-2026, 06:49 PM
      0 responses
      557 views
      1 like
      Last Post RFrosty
      by RFrosty
       
      Working...
      X