Announcement

Collapse
No announcement yet.

the API to find the barindex of a bar corresponding to a given time

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • the API to find the barindex of a bar corresponding to a given time

    I'd like to find out the bar index of a bar corresponding to a given date (for example, the next option expiry day). I think I saw such an EFS API somewhere before but I can not recall its name and syntex and can not find it in chm file. Can someone help me?

    - Clearpicks

  • #2
    Hello Clearpicks,

    Were you thinking of getFirstBarIndexOfDay()?
    Jason K.
    Project Manager
    eSignal - an Interactive Data company

    EFS KnowledgeBase
    JavaScript for EFS Video Series
    EFS Beginner Tutorial Series
    EFS Glossary
    Custom EFS Development Policy

    New User Orientation

    Comment


    • #3
      Hello JasonK,

      It does not work because it seems it can not look forward. If passing a future date to the api, it just returns null. Anyway I have figured out a bruteforce metthod to find out the bar index.

      - Clearpicks

      Comment


      • #4
        Clearpicks, What was the solution you came up with? I too am trying to find the bar index for a specific date (or time). I want to calculate the number of bars between two dates. And to draw something from the start date to the end date.

        Comment

        Working...
        X