I am working with data generated using high-resolution clocks. It has duration of certain events measured with fractions of seconds.
I find that when converting this to time format Stata produces a missing value where I do not expect it.
The following minimal example illustrates what is going on:
Results in the following execution log on Stata for Windows v15.0:
Milliseconds are more than enough for my analysis, so the storage type is fine. But I believe if Stata can't handle precision beyond a millisecond it should round up the value prior to the conversion rather than failing the whole value to a missing.
Thank you, Sergiy
I find that when converting this to time format Stata produces a missing value where I do not expect it.
The following minimal example illustrates what is going on:
Code:
clear all version 15.0 display clock("19:46:01","hms") display clock("19:46:01.1","hms") display clock("19:46:01.12","hms") display clock("19:46:01.123","hms") display clock("19:46:01.1234","hms") display clock("19:46:01.12345","hms")
Code:
. clear all . version 15.0 . . display clock("19:46:01","hms") 71161000 . display clock("19:46:01.1","hms") 71161100 . display clock("19:46:01.12","hms") 71161120 . display clock("19:46:01.123","hms") 71161123 . display clock("19:46:01.1234","hms") . . display clock("19:46:01.12345","hms") .
Thank you, Sergiy
Comment