bar count

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #29037 quote
    Abz
    Participant
    Veteran

    hello

    is there an easy way to count candles for example count how many green and red candles in ceratin time periode and sums up green and red candle ?

    thanks

    #29399 quote
    JC_Bywan
    Moderator
    Master

    Hi,

    You can use the keyword “summation” for this, let’s say you want to check how many candles during the past 25 ones have a close>open, then this number would be returned with:

    N=summation[25](close>open)

    From there, you can adapt to what you really want, replace 25 with the fixed or calculated number of candles you want to look back in time, or replace close>open with conditions for another type of candle you want…

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

bar count


ProOrder: Automated Strategies & Backtesting

New Reply
Author
author-avatar
Abz @abbas_sadiq Participant
Summary

This topic contains 1 reply,
has 2 voices, and was last updated by JC_Bywan
8 years, 11 months ago.

Topic Details
Forum: ProOrder: Automated Strategies & Backtesting
Language: English
Started: 03/18/2017
Status: Active
Attachments: No files
Logo Logo
Loading...