You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
Open+Close is not the size of the body. High+ (Low/3) is not the size of the size of tail.
Body size is Close - Open only for bullish candles.Please try to use SRC button when posting code; it makes it a lot easier to read (I've modified your post above).
Firstly, you are using doubles (numbers) to store something that should really be boolean (true/false), no?
Take a look here for a good guide about doing lookbacks correctly.
The easier approach (in my opinion) is to have distinct function calls for your patterns.
An example using the new format:
Finally, I'll just point out that you are reinventing the wheel. There are plenty of these pattern-finding indicators already available.
If you're doing it as an exercise to learn, that is great! But I just thought I'd point it out in case you didn't know.
Good luck!