4 Replies Latest reply: Oct 2, 2010 9:53 AM by Michael Solomovich RSS

    Time

    Jean-Jacques Jesua

      Hi

      I have a variable T representing a time. This variable is store in the original data as numeric like this :

      829, 1200, 1659, 2355

      829 means 8H 29 minutes

      1200 means noon

      I'd like to transform my variable in a new one which I could use as really time variable (hh:mm) to do some laps calculation.

      Thanks in advance for any help

      JJ

       

       

       

       

       

       

       

       

        • Time
          Michael Solomovich

          This will work:

           

           

          =

          time(time#(num(YourTimeField, '0000'), 'hhmm'))

          The part num(YourTimeField, '0000') make all values 4-digits long. The time#() "explains" the format. Function time() converts to "noraml" format.





            • Time
              Chris Hopkins

              Hi Michael,

              I have the same issue, My times are displayed as numbers, but mine include seconds, so they are a maximum of 6 numbers long. I assume i just add two extro zeros in the example you gave.

              i.e.

              =



              time(time#(num(TransStartTime, '000000'), 'hhmmss')) ,

              But how would i write this into my script?

              Chris

            • Time

              You could divide your time in seconds by 86400 (total number of seconds in one day) then display as time/timestamp format in the "number" tab