Announcement

Collapse
No announcement yet.

functions returning wrong values

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

  • functions returning wrong values

    Greetings:

    I am getting some values returned by a function that seem to be incorrect. I am running these in a chart for AB #F,2 in v7.91.

    1. sma(1, hlc3(), sym("TY #F,D"))

    returns: 689.90, when the value should be: 109.13

    2. high(sym("TY #F,D"))

    returns: 109.61, when it should be: 109.20

    3. low(sym("TY #F,D"))

    returns: 109.02, when it should be: 109.00

    4. close(sym("TY #F,D"))

    returns: 109.59, when it should be: 109.19

    Any ideas?

    Regards,
    Warren

  • #2
    Warren
    1. The syntax is incorrect. Should be sma(1,hlc3(sym("TY #F,D")))
    With regards to your other questions those differences are due to the fact that you are comparing decimals and 32nds [and a half].
    Alex

    Comment


    • #3
      OK, I understand the syntax comment, but not your comment about: "comparing decimals and 32nds and a half".

      Also, if I use:

      sma(1,hlc3(sym("TY #F,D"))) it returns a value that appears wrong, but I assume has to do with your decimal comparison comment.
      Last edited by werosen; 12-24-2005, 03:09 PM.

      Comment


      • #4
        Warren
        TY trades in 32nds and a half but the value you get from your function sma(1,hlc3(sym("TY #F,D"))) is expressed in decimals. Hence 109.40625 is equal to 109 13/32nds
        Alex

        Comment


        • #5
          Alex:

          OK, I get it now.

          Thanks a lot for the help and have a good Holiday.

          Warren

          Comment

          Working...
          X