One way is to find the value for current bar and previous bar but when you calculate on each tick this might give a false values.
Announcement
Collapse
Looking for a User App or Add-On built by the NinjaTrader community?
Visit NinjaTrader EcoSystem and our free User App Share!
Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less
Partner 728x90
Collapse
NinjaTrader
Slope of an oscillator
Collapse
X
-
Slope of an oscillator
Is there a way to find the slope of an oscillator (say for example MACD fast line) - all i need to know is +ve or -ve slope.
One way is to find the value for current bar and previous bar but when you calculate on each tick this might give a false values.Tags: None
-
Hello ark321,
Thanks for your post.
You can use the Slope() method which can be applied to any data series: https://ninjatrader.com/support/help...html?slope.htm
If you only want to check once per bar in a script running with Calculate.OnEachTick, you can use the system bool of IsFirsTickOfBar: https://ninjatrader.com/support/help...ttickofbar.htm (See usage example in help guide).
Paul H.NinjaTrader Customer Service
Latest Posts
Collapse
Topics | Statistics | Last Post | ||
---|---|---|---|---|
Started by Skifree, Yesterday, 11:38 PM
|
1 response
15 views
0 likes
|
Last Post Today, 11:32 AM | ||
Started by Mathias79, Today, 10:38 AM
|
6 responses
21 views
0 likes
|
Last Post Today, 11:29 AM | ||
Started by eladlevi, Today, 11:02 AM
|
1 response
6 views
0 likes
|
Last Post Today, 11:24 AM | ||
Started by Skifree, Yesterday, 11:41 PM
|
2 responses
13 views
1 like
|
Last Post
by eDanny
Today, 11:08 AM
|
||
Started by TraderCro, 04-12-2024, 11:36 AM
|
8 responses
105 views
0 likes
|
Last Post Today, 11:06 AM |
Comment