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
How to say 'If candlestick pattern found within last X candles'?
Collapse
X
-
Tags: None
-
-
Hello demo166130,
Thanks for your post.
You would need to set the "Trend strength" on the Candlestick pattern indicator to change the number of required bars to the left and right of the swing point used to determine trend.
https://ninjatrader.com/support/help...ickpattern.htm
Josh G.NinjaTrader Customer Service
Comment
-
Im actually using th Strategy Builder so info based around using C# isn't all that helpful, unless I've missed something in the link you provided which is entirely possible. I would like the Builder to say 'IF candlestick pattern X has occured within the last X bars'
Comment
-
I tried saying 'If Candle stick pattern X Equals True' but thats not compatible with the Builder. Is it supposed to be If candlestick pattern X is candlestick pattern x, so both sides of the condition builder show the same indicator?
Can you also confirm that the trend strength means, let's say in the case of an engulfing candle, if the strength was set to 4, it would only trigger if the engulfig candle was greater in size than the previous 4 candles? Is that the meaning of this?
Comment
-
demo166130,
No you didn't miss anything. Just giving you a reference to see what parameters can actually be set for that indicator.
Does setting TrendStrength to X not give you the desired results?
If not, there likely will not be a way through the Strategy Builder.
Josh G.NinjaTrader Customer Service
Comment
-
I think your missing what I'm unable to do because it is so simple. The Trend Strength helps determine the strength of the candletick, but some candlesticks aren't determined by the trend strength indicator, such as the 'evening star', so I'm looking for a way to say 'if candlestick pattern X has shown itself in the last X bars'. Even if you confirm that isn't possible using the builder, can you explain how you write into the builder the way to say 'If candlestick X occurs', because at present saying 'If Candlestsick X == True' isn't a valid input
Comment
-
demo166130,
I am not talking about a trend strength indicator here. In this context TrendStrength is referring to the parameter for the CandlestickPattern Indicator.
As seen in the example from the help guide, you would need to compare the candlestick pattern to "1" or "0" instead of true/false.
Josh G.NinjaTrader Customer Service
Comment
-
Im with you, I wasn't referring to a trend strength indicator despite using the phrase. Im trying to understand if it is possible to say 'if candlestick pattern X has ben observed within the last X number of candles' in the same way there exists a lookback period with some indicators to see whether the indicator signal has occurred in the last X number of bars. Adjusting the trend strength only filters out the strength of the candle signal.
Even if there isn't a way to do what I'm asking, which seems a little odd because on the surface it isn't that complicated, how would I say to the builder 'If candlestick pattern X occurs'? Would I use Equals and then write the exact same candlestick pattern on the right side of the equation in the Strategy Builder?
Comment
-
-
Good to know, thanks chaps. So negative 1 would be false?
But still no way to say 'If pattern has occured with the last 5 bars'?
Comment
Latest Posts
Collapse
Topics | Statistics | Last Post | ||
---|---|---|---|---|
Started by suroot, 04-10-2017, 02:18 AM
|
4 responses
3,021 views
0 likes
|
Last Post
by truepenny
Today, 08:01 AM
|
||
Started by Stanfillirenfro, Today, 07:23 AM
|
1 response
6 views
0 likes
|
Last Post Today, 07:37 AM | ||
Started by cmtjoancolmenero, Yesterday, 03:58 PM
|
2 responses
22 views
0 likes
|
Last Post Today, 07:24 AM | ||
Started by olisav57, Yesterday, 07:39 PM
|
1 response
9 views
0 likes
|
Last Post Today, 07:23 AM | ||
Started by cocoescala, 10-12-2018, 11:02 PM
|
7 responses
944 views
0 likes
|
Last Post
by Jquiroz1975
Today, 07:21 AM
|
Comment