Morning Star rules not respected

Forums ProRealTime English forum ProBuilder support Morning Star rules not respected

  • This topic has 20 replies, 3 voices, and was last updated 5 years ago by avatarBard.

Tagged: 

Viewing 15 posts - 1 through 15 (of 21 total)
  • #94059

    Hi

    I can’t find a good Morning Star candlestick pattern on here that respects Charles Bulkowski’s definition. He is regarded as the master on candlestick studies publishing % return tables for candlestick patterns. See http://thepatternsite.com/MorningStar.html

    Eg: MorningStar,  Bullish Reversal, Accuracy = 78% in a Bull Market/65% Bear Market with a very low occurrence.

    I have amalgamated different code from prorealcode to obtain the closest to Bulkowski’s definition for this pattern. In the first screenshot the last green candle (with a white arrow after the Morning Star) doesn’t respect the rule that it should climb up to over half the opening candles body length (first long white long candle), probably because maybe I haven’t coded it correctly?

    I think adding a bullish pinbar code (on this forum) for extending the Morning Star candle shadow may also help to respect the rules further.

    (First screen Morning Star pattern from XAGUSD Daily 9th Feb 2000)

     

    #94064

    I suggest that lines 1 through 7  be moved AFTER line 11, since at line 2 BODY has not yet been defined, so it will refer to the body of the previous candlestick.

     

     

    #94087

    Thanks @Robertogozzi, that makes logical sense, problem is that it now produces zero Morning Stars patterns? There were 4 with Daily Silver so I relaxed the rules for longcandle= (ratio>0.7) changing it to longcandle= (ratio>0.5) and also (open[2] close[2]/1.5) changing it to (open[2] close[2]/2). No patterns. I have tried it on 10,000 units of Daily silver, £/$ $/CHF and £/Yen, yet no patterns? (Please screens of “Morning Star 2” indicator now missing whereas the second image shows it produced a pattern before reversing the body code)

    #94096

    I changed it a bit:

    I used it on the price chart, not below.

    The second and third last lines are intended to use the variable SIGNAL only (dummy lines).

    As you can see I commented out many unnecessary lines and modified line 28 (your line 35).

    I also addet the first two line to set offset values to plot at a distance from the candles.

    I also changed line 6 (your line 2).

    Few patterns were found, but this may depend on settings. The pattern recognition seems to work.

     

    1 user thanked author for this post.
    #94130

    That’s much appreciated @Robertogozzio, thanks for re-writing this code,

    A number of thoughts occur to me:

    Can you think why the first candle of the Morning Star formation is still very short? In your first screenshot both red candles don’t have a long body. I believe this is a crucial part of the pattern where the Bears think they have the upper hand and then the price gaps down to the Star candle only to powerfully reverse direction after it, (i.e. an exhaustion point).

    There appears to be no gap between the opening of the third green candle and the Morning Star candle in the first two examples? (Hence the name “Star”).

    Also I think it’s important for the third green candle to cover / retrace back to at least over half the height of the first long red candles body – which they do – but in these examples is that only because the first red candles are all short in body?

    Nice offset tip too!

    Cheers
    Bard

    #94142

    Line 10 (my version’s)  deals with the size of the body, but not with the size of the range. A big body is only evaluated with reference to its range, if it’s a candle having a small range, then its body will be even smaller!

    You must define a way to translate into code what you would do when sitting in front of your PC; when you watch your charts, when do you say “this candle is big enough”:

    1. when it has a big range, regardless of its body size?
    2. when it has a big body, regardless of its range?

    then code then accordingly. You might use averages to compute the average (body or range) size of the last, say 50, candle and consider a candle as being a big one if it exceeds that average.

    Example 1 (body size average):

    Example 2 (body size in relation to the average range size):

     

     

    1 user thanked author for this post.
    #94337

    Thanks for explaining the issue @Robertogozzi.

    I added the second option:

    ..and yet there is still a small red (white) candle as the first candle of the formation even though I upped the RangeSize to 0.9? Range size has some big candles: Pls see screenshot. I also tried the first option with the pattern still showing despite the opening small down candle.

    Any ideas how to get rid of these dwarf candles!? (on the crosshair in image)

    Cheers

    #94339

    You could replace line 5 with:

    but if you think LongCandle is too much for the second previous candle, then you can define a smaller LongCandle and use both definitions (with different names):

     

    1 user thanked author for this post.
    #94352

    Thanks very much again for the modifications, right.. there was a LongCandle in previous versions, not that it worked then.

    Thing is, even with the exact same code as above or even with slight modifications to your code (swapping the LongCandles), to really follow Bulkowski’s definition as close as possible — (i.e. large first red candle and the last green candle’s price, after the Morning Star, must climb at least over half way into the red body of the first red candle) — this code still produces a “red dwarf?”

    I also notice my first post didn’t contain the images from Bulkowski’s book, which I tried twice to upload, thinking the second time had been successful. I’m going to try again here with at least one of the screens:

    #94357

    There’s no requirement for the long black candle, it just needs to be long.

    It’s up to anyone one defining how long enough is LONG.

    If you think an average does not help, you can replace it with the sum of the previous 2-3 candles’range or maybe the previous one multiplied by some factor.

    Look at your chart and when you see a candle and think “this is not a dwarf”, well… code exactly what your eyes see.

    1 user thanked author for this post.
    #94358

    Also realised this code will need to be added…:

    …so this exhaustion point spike on the green candle (after the Morning Star) is taken account of and avoids a Morning Star signal being given (see Morning Star 4 indicator) :

     

     

    #94365

    The more rules you add, the less clear and uncertain your definition will be!

    There are a million candlestick combinations around, you cannot follow any DWARF candle your eyes see and get rid of it…. you’ll need a million rules!

    Have ONE rule, you’ll get rid of, say 67-75 %, of dwarfs; still, you’ll have have some left. It’s like a strategy, no strategy will EVER have a 100% winning rate!

    Few simple rules, few simple lines of code, few indicators, few… everything will prove to be more winning than anything else.

    In the second last pic you attached you can read “ignore the shadows in this candlestick pattern“. DO stick to this rule.

     

    1 user thanked author for this post.
    #94368

    no strategy will EVER have a 100% winning rate!

    Not quite true.

     

    #94369
    • no strategy will EVER have a 100% winning rate!

      Not quite true.

    • Any overnight fee/rollover?
    • Would you have opened that trade on Jan. 1st, 1970?

     

    #94381

    Any overnight fee/rollover? Would you have opened that trade on Jan. 1st, 1970?

    Even with fees it has a 100% win rate.

    No I wouldn’t have bought as I was only a few months old and so unable to open an account with a broker due to silly age restrictions.

Viewing 15 posts - 1 through 15 (of 21 total)

Create your free account now and post your request to benefit from the help of the community
Register or Login