Announcement

Collapse
No announcement yet.

compare column with time stamps with +- tolerance

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

  • compare column with time stamps with +- tolerance

    Hello!

    I have files that come in the following format:
    timestamp with 0.1 sec accuracy <Tab> Type

    e.g.
    Time Type
    00:00:00.5 2
    00:00:01.3 2
    00:00:02.1 2
    ...

    I'd like to be able to compare 2 such files.
    *) If types differ that is a strong difference.
    *) If the type is identical but the time difference is < 0.3 sec that is less important.

    Is that achievable with BC?
    (Naturally I can write converters that convert the timestamp e.g. into a float value if that helps.)

  • #2
    re-post...

    Uups. Just found an old posting, it seems I already had the same problem a couple of years ago...
    http://www.scootersoftware.com/vbull...ead.php?t=4543

    Comment


    • #3
      How did the previous suggestion work for you? Defining the milliseconds into their own column.
      Aaron P Scooter Software

      Comment


      • #4
        Defining milliseconds into a separate column doesn't work as times like

        00:00:01.9 and
        00:00:02.1

        or

        00:00:59.9 and
        00:01:00.1

        would be reported as different even though they are only 0.2 sec apart.

        Now I wrote a converter to automatically re-format files the following way:
        *) 1st column = a sort of line number
        *) 2nd column = time in seconds
        *) 3rd col = time in "normal" format

        BeatNr RelTime Time Type
        0 1,2 00:00:01.2 2
        1 1,9 00:00:01.9 2
        2 2,6 00:00:02.6 2
        3 3,4 00:00:03.4 2

        Then I marked the 3rd column as unimportand and specified a numeric tolerance of 0.3 for the 2nd column. That works perfectly (BC, the best program EVER

        But: I have to make this session setting changes every time I want to compare such files. Or I make that the default session then ALL csv-comparisons use that session settings.

        Is it possible to link this session settings to a specific file name extension (e.g. "*.bea") - so that "normal" .csv file remain the way they are and .bea files use this configuration?

        Thanks in advance!

        Comment


        • #5
          resolved!

          Forget my request.
          I need to write a module that supports the validation anyway, so comparing with BC - which is still the best software ever - is not needed anymore.

          Ralf

          Comment

          Working...
          X