Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • table X tab commands behavior on %tc clock format

    Hi, based on the followind data sample.


    Code:
    clear
    input double datastatus
    2026107070200
    2026020284107
    2026280684440
    2026196029990
    2026107085497
    2024818643800
    2.0222784e+12
    2023947443500
    2.0222784e+12
    2.0222784e+12
    2025939214983
    2025939214983
    2025939183233
    2026453983037
    2026020284147
    2026540906450
    2023947435587
    2023947435503
    2026540906290
    2025939183233
    2023947435550
    2.0222784e+12
    2026365565373
    2026540906293
    2025939208080
    2024818643703
    2026365565097
    2026540906407
    2026195997763
    2026195997767
    2026453983130
    end
    format %tc datastatus

    I was expecting to receive back the same output, regardless of table or tab commands.

    Code:
    . tab datastatus
    
     DataStatus |      Freq.     Percent        Cum.
    ------------+-----------------------------------
      31jan20.. |          4       12.90       12.90
      19feb20.. |          1        3.23       16.13
      19feb20.. |          1        3.23       19.35
      19feb20.. |          1        3.23       22.58
      19feb20.. |          1        3.23       25.81
      29feb20.. |          1        3.23       29.03
      29feb20.. |          1        3.23       32.26
      13mar20.. |          2        6.45       38.71
      13mar20.. |          1        3.23       41.94
      13mar20.. |          2        6.45       48.39
      14mar20.. |          1        3.23       51.61
      14mar20.. |          1        3.23       54.84
      15mar20.. |          1        3.23       58.06
      15mar20.. |          1        3.23       61.29
      16mar20.. |          1        3.23       64.52
      16mar20.. |          1        3.23       67.74
      16mar20.. |          1        3.23       70.97
      17mar20.. |          1        3.23       74.19
      18mar20.. |          1        3.23       77.42
      18mar20.. |          1        3.23       80.65
      19mar20.. |          1        3.23       83.87
      19mar20.. |          1        3.23       87.10
      20mar20.. |          1        3.23       90.32
      20mar20.. |          1        3.23       93.55
      20mar20.. |          1        3.23       96.77
      20mar20.. |          1        3.23      100.00
    ------------+-----------------------------------
          Total |         31      100.00
    
    
    . table datastatus
    
    ---------------------------------
                         |  Frequency
    ---------------------+-----------
    DataStatus           |           
      04jan2024 15:06:40 |          1
      29apr2024 08:53:20 |          1
      Total              |         31
    ---------------------------------
    Am I missing something here?

    thks



  • #2
    This is another example of a bug in modern (Stata 17 and newer) table command. We hope to have this fixed in the next Stata update.

    For reference, here is the earlier post about this bug in table: link

    Comment


    • #3
      The Stata 18 update on 04apr2024 fixes this.
      The fix for this in Stata 17 will be in its next update.

      Comment

      Working...
      X