Sign Up

Have an account? Sign In Now

Sign In

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask question.

Forgot Password?

Need An Account, Sign Up Here
Sign InSign Up

First independent community of traders

First independent community of traders Logo First independent community of traders Logo

First independent community of traders Navigation

  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • Buy Theme
  • Home
  • About Us
  • Blog
  • Contact Us
Home/ Questions/Q 6413
Next
In Process
savinkins
savinkins

savinkins

  • 1 Question
  • 15 Answers
  • 0 Best Answers
  • 46 Points
View Profile
  • 0
savinkins
Asked: January 27, 20212021-01-27T07:23:54+00:00 2021-01-27T07:23:54+00:00In: Forex Expert Advisors

Getting data by the indicator from another indicator on a larger time frame

  • 0
Getting data by the indicator from another indicator on a larger time frame

Hello.
In the indicator (5 min TF), I try to get data from another indicator (1 hour TF). The system returns error 4806 – “The requested data was not found”. However, if the second indicator (with a larger TF) is running on a parallel chart, then my indicator works. How do I get the indicator to work without opening the second chart?
For example, I made an indicator that I run for 5 min. TF. It also tries to get the data of the ATR indicator from the watchmaker.

Returns an error:

But it doesn’t give out like this:

Help me figure out how to properly run my indicator on a smaller timeframe.

  • 6 6 Answers
  • 0 Followers
  • 0
Answer
Share
  • Facebook

    6 Answers

    • Voted
    • Oldest
    • Recent
    1. savinkins

      savinkins

      • 1 Question
      • 15 Answers
      • 0 Best Answers
      • 46 Points
      View Profile
      savinkins
      2021-01-27T07:24:37+00:00Added an answer on January 27, 2021 at 7:24 am

      Alexey Kozitsyn:
      Hello. On each tick, you need to check the synchronization of the older TF. I.e., call the SeriesInfoInteger() function with the synchronization ID (see the documentation). Or call the Bars() function with the appropriate symbol/TF and compare with -1. As far as I remember, if the timeseries are not synchronized, then synchronization will return false, and Bars () will return -1. Also, you need to compare the number of calculated bars (Bars ()) and the number of calculated bars of the indicator (BarsCalculated ()) for equality. 

      Bars () returns -1. As far as I understand, synchronization is needed when the information does not have time to load. And here it does not go at all.

      • 0
      • Reply
      • Share
        Share
        • Share on Facebook
        • Share on Twitter
        • Share on LinkedIn
        • Share on WhatsApp
    2. ich_hub

      ich_hub

      • 0 Questions
      • 2 Answers
      • 0 Best Answers
      • 24 Points
      View Profile
      ich_hub
      2021-01-27T07:24:31+00:00Added an answer on January 27, 2021 at 7:24 am

      Try to solve the problem using non-standard methods. For example, so:

      • 0
      • Reply
      • Share
        Share
        • Share on Facebook
        • Share on Twitter
        • Share on LinkedIn
        • Share on WhatsApp
    3. komposter

      komposter

      • 1 Question
      • 37 Answers
      • 0 Best Answers
      • 94 Points
      View Profile
      komposter
      2021-01-27T07:24:25+00:00Added an answer on January 27, 2021 at 7:24 am

      savinkins:

      Tell me if there are relatively simple, standard solutions. I need this mechanism for use in the indicator, which is already very “heavy”. If I run several Expert Advisors with such overloaded indicators, nothing good will come out.

      The Expert Advisor is easier to synchronize. If you do not need visualization on another TF, do not bother, but connect the indicator from the desired TF to the Expert Advisor.

      • 0
      • Reply
      • Share
        Share
        • Share on Facebook
        • Share on Twitter
        • Share on LinkedIn
        • Share on WhatsApp
    4. alexeyvik

      alexeyvik

      • 1 Question
      • 78 Answers
      • 0 Best Answers
      • 180 Points
      View Profile
      alexeyvik
      2021-01-27T07:24:13+00:00Added an answer on January 27, 2021 at 7:24 am

      savinkins:
      I thought that the problem is known, so they will tell you. But thanks for the advice. Here is the file.

      The problem is not only well-known, but also well-known

      Forum on trading, automated trading systems and testing of trading strategies

      The requested data was not found.

      Alexey Viktorov, 2017.07.08 10:39

      The question was raised back in September 2016, but nothing was fixed or I could not find a solution to the problem?

      For some reason, this problem does not occur in the Expert Advisor, and in the indicator it is not possible to request the data of the period indicator that does not correspond to the current one. And the answer to this post also could not be found for a reason… I’d rather not say anything.

      Please help me. Maybe someone knows where there is an answer, or they will answer more specifically

      Task: to get the values of the fractals of the period H1 when the indicator is launched on the period M5.

      int hadle;
      double arr[];
      /**************Custom indicator initialization function**************/
      int OnInit()
      {
         hadle = iFractals(_Symbol, PERIOD_H1);
         int size = CopyBuffer(hadle, 0, 0, 1000, arr);
         if(size < 0)
          {
           Print("CopyBuffer error", GetLastError());
          }
         return(INIT_SUCCEEDED);
      }/*******************************************************************/

      And it absolutely does not matter where to place CopyBuffer () in OnInit () or in OnCalculate()

      I even tried opening a new chart window with the specified period H1

      long idChart = ChartOpen(_Symbol, PERIOD_H1);

      add an indicator to it, or apply a template with an indicator to update this chart

         ChartIndicatorAdd(idChart, 0, hadle);
         ChartRedraw(idChart);
      nothing helps, the result is

      ERR_INDICATOR_DATA_NOT_FOUND

      4806

      The requested data was not found

      there are also links to other topics.

      • 0
      • Reply
      • Share
        Share
        • Share on Facebook
        • Share on Twitter
        • Share on LinkedIn
        • Share on WhatsApp
    5. savinkins

      savinkins

      • 1 Question
      • 15 Answers
      • 0 Best Answers
      • 46 Points
      View Profile
      savinkins
      2021-01-27T07:24:07+00:00Added an answer on January 27, 2021 at 7:24 am

      -Aleks-:

      I recommend that you attach the indicator as a file to start with – few people will work with the picture…

      I thought that the problem is known, so they will tell you. But thanks for the advice. Here is the file.

      • 0
      • Reply
      • Share
        Share
        • Share on Facebook
        • Share on Twitter
        • Share on LinkedIn
        • Share on WhatsApp
    6. -aleks-

      -aleks-

      • 2 Questions
      • 39 Answers
      • 0 Best Answers
      • 80 Points
      View Profile
      -aleks-
      2021-01-27T07:24:00+00:00Added an answer on January 27, 2021 at 7:24 am

      savinkins:

      Hello.

      In the indicator (5 min TF), I try to get data from another indicator (1 hour TF). The system returns error 4806 – “The requested data was not found”. However, if the second indicator (with a larger TF) is running on a parallel chart, then my indicator data works. How do I get the indicator to work without opening the second chart?

      For example, I made an indicator that lasts for 5 minutes. The TF tries to get the ATR indicator data from the watchmaker.

      Returns an error:

      But it doesn’t give out like this:

      Help me figure out how to properly run my indicator on a smaller timeframe.

      I recommend that you attach the indicator as a file to start with – few people will work with the picture…

      • 0
      • Reply
      • Share
        Share
        • Share on Facebook
        • Share on Twitter
        • Share on LinkedIn
        • Share on WhatsApp
    Leave an answer

    Leave an answer
    Cancel reply

    Browse

    Sidebar

    Ask A Question

    Stats

    • Questions 530
    • Answers 2k
    • Posts 5
    • Comments 0
    • Best Answers 0
    • Users 748
    • Popular
    • Comments
    • Tags
    • forexcommunity

      Highlighting what’s important about questions & Answers on Discy Community!

      • 0 Comments
    • forexcommunity

      Introducing Keyboard Shortcuts, our first Labs feature

      • 0 Comments
    • forexcommunity

      Defining quality on Discy Engine — what a helpful answer ...

      • 0 Comments
    • forexcommunity

      Organizational and company accounts on Discy Engine the next step

      • 0 Comments
    • forexcommunity

      Hello world!

      • 0 Comments

    Related Questions

    • BrantHaps

      write my essay ndl

      • 0 Answers
    • Galengask

      write my paper qxg

      • 0 Answers
    • Johnbup

      Слоты в онлайн казино. Игровые автоматы бесплатно

      • 0 Answers
    • StephenWaibe

      Торгуйте акциями основных технологических компаний США

      • 0 Answers
    • Doublebtc-Ceact

      DoubleBTC.WIN - Double your bitcoin in 24 hours

      • 0 Answers

    Users

    LouisJah

    LouisJah

    • 0 Questions
    • 0 Answers
    JoshuaCrymn

    JoshuaCrymn

    • 0 Questions
    • 0 Answers
    ElmerEcoth

    ElmerEcoth

    • 0 Questions
    • 0 Answers

    Footer

    First independent community of traders

    About

    An independent community of forex traders. This is where traders communicate. You can ask your questions and you will receive an answer to your question.
    • Terms of Use
    • Privacy Policy
    • Cookie Policy
    • Knowledge Base
    • Support

    © 2021 Forexcommunity.net. All Rights Reserved