"date" in easylanguage

Discussion in 'Strategy Development' started by travis, Jul 17, 2003.

  1. travis

    travis

    If "990101" is "January 1, 1999", please how do I say "January 1, 2003"?
     
  2. Monsoon

    Monsoon

    just a guess from the IQ test-like manner of your post...


    030101
     
  3. travis

    travis

    Yes, of course, thank you for replying, but this answer doesn't work. That is why I thought it could have been something different.
     
  4. not to be a jerk, but you can easily find these types of answers in the online manual. the correct number is 1030101
     
  5. TGregg

    TGregg

    Nope. 1030101 is 1/1/03. They tack that extra one on the front so you can get the expected results from comparing to dates in 1999. For example, suppose you had two dates, 1/1/99 in Variable1 and 1/1/03 in Variable2, and you wanted to see which was greater. If Variable1=990101 that would be greater than 030101. But, if TS used 1030101 and 990101 the conditional works out as expected.

    EDIT: As an aside, use the print command to figure out things you don't understand. print(variable1); prints the value of variable1 to the Easy Language Output Bar.

     
  6. travis

    travis

    Fantastic, this one works now. Thank you all. (I will also look from now on, at the online manual, since the one I have only goes up to 1999 examples). I am using "date" to add a walk forward optimization feature in my signal.