control number of bearish candles for a pullback??

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #159793 quote
    Ha
    Participant
    New

    Hi,

    How do you code a pullback that you limit a number of bearish candles? I looked in the library but can’t find anything I could modify…

    Say, I look for stocks to trend above 20EMA then pulls back. Here, I want at least two red candles down but no more than five.

    And how can I identify that swing high? I’d like to enter when this pullback breaks that swing high.

    Thank you.

    #159798 quote
    robertogozzi
    Moderator
    Master

    There you go:

    Bearish = close < open
    c1      = summation[5](Bearish)
    c2      = summation[6](Bearish)
    Cond    = (c1 >= 2) AND (c2 = c1)

    Cond, if true, grants that there have been at least 2 bearish candle, but not more than 5.

Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.

control number of bearish candles for a pullback??


ProScreener: Market Scanners & Detection

New Reply
Author
author-avatar
Ha @ha Participant
Summary

This topic contains 1 reply,
has 2 voices, and was last updated by robertogozzi
5 years, 1 month ago.

Topic Details
Forum: ProScreener: Market Scanners & Detection
Language: English
Started: 01/29/2021
Status: Active
Attachments: No files
Logo Logo
Loading...