Announcement

Collapse
No announcement yet.

Price precision with AB & MC symbols

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

  • Price precision with AB & MC symbols

    While backtesting a system on the miniRussell(AB/ER2), and the miniS&P400MidCap(MC/EMD) using AB #F and MC #F=2, I'm seeing issues with the prices that should be in tenths.

    What should be xxx.80 shows as xxx.79, and...
    xxx.10 shows as xxx.09
    xxx.30 shows as xxx.29
    xxx.60 shows as xxx.59

    This rounding anomaly causes problems when attempting to transmit orders to TWS via DynaOrder as well. Very frustrating.

    I've attached a screen shot of the eSignal Back Tester output running on the AB #F contract.

    Anyone out there with similar experiences, and possibly a fix??
    __
    JO
    Attached Files

  • #2
    JO - I have seen this same issue but don't know what causes it. What's worse is if you try and print one of these "oddball" numbers on a chart because its not 610.09 its actually more like 610.099999999999999999999999999.

    To get around this, I have used the Math.floor/ceiling/round functions as well as toFixed(2) for display.

    I'll be interested to hear from Jason or Alex on what is actually giong on with this.

    Comment


    • #3
      Hello ebr/TraderJo,

      What's happening is that if a number is passed to the Strategy Analyzer in it's raw format, the Analyzer is not doing any rounding for you, but rather parsing the value to a certain number of decimal places as a string. This is a known issue. I'll pass another note about this to development. For now, you need to apply some rounding or one of the workarounds ebr has mentioned.
      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


      • #4
        By the way, this issue is in our EDL list, case number 11175.
        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


        • #5
          Hi ebr and Jason,

          Thanks for the replies. I'd already tried massaging the data as ebr suggested, and odd results still appear.

          Everything displays fine on the charts; in the formula output window; and my log files. However, there are internal eSignal things going on that mess with the variables received by the back tester, or sent through to third party interfaces like DynaOrder. The attached screen shot shows what appears in the DO Host. The orders appear in TWS properly formatted !, BUT then I need to manually Modify/Transmit the orders flagged with the improper price error. Kind of defeats the prupose of trade automation, don't you think. I'm in the process of writing another price conversion function for futures priced in tenths. We'll see what happens.

          Jason, this is a serious problem, and it should have been resolved ages ago. Perhaps it's some bug in the Microsoft C libraries, which wouldn't surprise me at all..

          This should be EDL Case #1. And Case #2 should be the other bug addressed in the thread located at:


          All the nice bells and whistles that keep getting added to advanced charts are nice, but hey.....I don't mind driving a rust bucket as long as the engine, transmission, brakes, and heater work; if you know what I mean
          __
          JO
          Attached Files

          Comment


          • #6
            Another interesting observation. After the close today, I changed some parameters of my AB system and ran a test. The trailing stop had moved up to 618.80, and then a bar developed that had a low of 618.80 on the chart, but the stop was not triggered. I assume this was because, "behind the scenes", the stop was valued internally as 618.799998 or some such nonsense. It took a low of 618.70 to trigger the stop at 618.80.

            Well, enough for the complaining. Time to write that new AB/MC price formatting function. Later....
            __
            JO

            Comment

            Working...
            X