Hi,
I am currently working with time data. The following is the time each person spends alone on each activity (25 activities, shown only 7 ), this includes missing values since the person is not alone for the given activity. I would like to see how much time each person spends alone in a day. Essentially I am trying to add the h1+h2+ h3+ h4+ h5 + h6+ .... for each individual (140 individuals). Can someone please help me with the same? Thank you
[CODE]
* Example generated by -dataex-. To install: ssc install dataex
clear
input float(h1 h2 h3 h4 h5 h6 h7)
. . 1800000 . 1800000 . .
. 3600000 3600000 3600000 . 7200000 3600000
. 1.08e+07 1.26e+07 1800000 1.08e+07 3600000 1800000
1.08e+07 1800000 1800000 1800000 1800000 3600000 .
. 1800000 5400000 1800000 1800000 3600000 3600000
1.08e+07 1800000 1800000 1800000 7200000 . 3600000
. . . . . 3600000 7200000
7200000 . . 7200000 . 3600000 .
end
format %tchh:MM:SS h1
format %tchh:MM:SS h2
format %tchh:MM:SS h3
format %tchh:MM:SS h4
format %tchh:MM:SS h5
format %tchh:MM:SS h6
format %tchh:MM:SS h7
Cheers,
Aarushi
Related Posts with Adding time variables
dataset normality issue (probit analysis)Hi all, I intending to employ simple probit, multinomial and Heckman selection model analysis to id…
If and commandHello, Can you help me please with my following issue? I have a panel data set and I want to figure…
Replacing value with previous value if value is outside certain intervalHi everyone, I have the following panel data (in total 1200 observations) Country Year ACC_POP A…
How do i include the results of a no observations regression into a matrix?So my problem is that i have a dataset of 502 firms but some of them have no observations. The thing…
Confidence intervals for gradients in npregressDear all, I'm trying to estimate confidence intervals for my gradients after performing a kernel re…
Subscribe to:
Post Comments (Atom)
0 Response to Adding time variables
Post a Comment