Announcement

Collapse
No announcement yet.

Old efs not updating on intra-day chart

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

  • Old efs not updating on intra-day chart

    Hi all,
    I am looking at the volume flow indicator back testing efs written back in 2004 and it doesn't update in real time on an intra-day chart. I have never had this problem before. Another VFI written in 2004 as well without the back testing code is updating fine.

    I tried figuring out the old code but its difficult given how simple EFS-2 coding is. The backtesting code does an additional manipulation to the data under back test #4 that I'd like to watch in real time. I just can't figure out how to get the efs to update or how to implement the logic from scratch in another efs.

    Any help is most appreciated!


    Jonathan

    PS: I'm trying to attach the efs, just not sure if its gonna work.
    Attached Files

  • #2
    Hello Jonathan,

    The two formulas you're referring to are currently working as they were intended to. They both have indicators that update in real time. The back testing formula's back testing conditions are only for back testing in the Strategy Analyzer.

    If you want to create a real time system from the back testing version you will need to track the position states with a global variable in place of the Strategy.isLong(), Strategy.isShort() methods. In place of the Strategy trading methods, .doLong() etc., is where you would assign the position state, "long,""short" or "flat" to your global variable. Some people use 1, -1 and 0 for the three states. You may also add an Alert or draw a shape, image or some text at these instances to signal the trade on the chart. Also make note of the first condition for the back testing section on line 269 that prevents the back testing code from executing on bar 0. I would recommend leaving the back testing section in place and duplicate the logic in a new section that will be allowed to process on bar 0 in real time. Give it a shot and if you run into any specific questions or problems, post your modified code and related details.
    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
      HI Jason,
      Thanks for the quick response. I will take a look at line 269 and adding the additional variables. While I understand the backtesting code won't execute on bar 0, does the logic to update the variables used in the backtesting section run? I can see easily adding the code to test conditions in real time, but only if those conditions are updating in real time. I hope that that makes sense?

      Thanks,

      Jonathan

      Comment


      • #4
        Jason,
        I am up and running. I had to move some code around, but it is working now in real time.
        Thanks for your help!
        JOnathan

        Comment


        • #5
          You're most welcome.
          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

          Working...
          X