Stocks with >254 bars?

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #170362 quote
    prtdbdb
    Participant
    New

    Hi there! 🙂

    Actually I’m working on version v11.1. I saw here that the bar limit for ProScreener should double, but I think it doesn’t. Can anybody confirm/deny this please?

    I’m working on a screener that gives me the total amount of bars and only selects the stocks with more than 254 bars. The code is this:

    if IsLastBarUpdate then
    
        if barindex < 254 then
            condition = 1
        else
            condition = 0
        endif
    
    endif
    
    SCREENER[condition](barindex as "barindex")

    The results I get give me BarIndex < 254 as expected, but when I compare it with another simple indicator that show me how many bars are there in total (script: return barindex), I see that some stocks actually have more than 254 bars, so I guess sometimes the screener executes on the last 254 bars and some other times less.

    Does anybody know why does this happens? How could I get a list of companies with more/less than 254 bars without errors?

    Thanks in advance!

    ScreenerBars.png ScreenerBars.png
    #170379 quote
    robertogozzi
    Moderator
    Master

    It was rumored that, but they did not change it.

    It works up to 254 bars, but you scan just the current condition.

    To scan the condition on the previous bar you will have to use:

    SCREENER[condition[1]](barindex[1] as "barindex")

    with SCREENER.

    #170392 quote
    prtdbdb
    Participant
    New

    Ok is good to know that they finally didn’t change that and its not my programming skills…

    Since I do all the calculations on IsLastBarUpdate, I don’t think condition[1] would help me.

    How can it be that the screener returns some stocks where the condition is true (therefore barindex < 254), and they still have more than 254 bars?

    #170394 quote
    robertogozzi
    Moderator
    Master

    It could be that since ProScreener scans the last 254, if for some unknown (to me) reasons some bars are missing it can tally less than 254 despite having more. It really has less than 254 WITHIN the last 254!

    But I’m just guessing trying to find out the most logical reason!

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

Stocks with >254 bars?


ProScreener: Market Scanners & Detection

New Reply
Author
author-avatar
prtdbdb @prtdbdb Participant
Summary

This topic contains 3 replies,
has 2 voices, and was last updated by robertogozzi
4 years, 9 months ago.

Topic Details
Forum: ProScreener: Market Scanners & Detection
Language: English
Started: 05/25/2021
Status: Active
Attachments: 1 files
Logo Logo
Loading...