Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
MTUS
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Ben Anderson
MTUS
Commits
6eae50ce
Commit
6eae50ce
authored
8 years ago
by
Ben Anderson
Browse files
Options
Downloads
Patches
Plain Diff
added codes for secondary acts (not quite the same)
parent
f92a7bd5
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
mtusFunctions.R
+73
-0
73 additions, 0 deletions
mtusFunctions.R
with
73 additions
and
0 deletions
mtusFunctions.R
+
73
−
0
View file @
6eae50ce
...
@@ -31,6 +31,79 @@ ba_tidyNum <- function(number) {
...
@@ -31,6 +31,79 @@ ba_tidyNum <- function(number) {
format
(
number
,
big.mark
=
","
,
scientific
=
FALSE
)
format
(
number
,
big.mark
=
","
,
scientific
=
FALSE
)
}
}
## Set up MTUS labels to MTUS activity codes 1:69 ----
# these need to match any other harmonised data
mtusDiaryLabels
=
c
(
"imputed personal or household care"
,
#1
"sleep and naps"
,
#2
"imputed sleep"
,
#3
"wash, dress, care for self"
,
#4
"meals at work or school"
,
#5
"meals or snacks in other places"
,
#6
"paid work-main job (not at home)"
,
#7
"paid work at home"
,
#8
"second or other job not at home"
,
#9
"unpaid work to generate household income"
,
#10
"travel as a part of work"
,
#11
"work breaks"
,
#12
"other time at workplace"
,
#13
"look for work"
,
#14
"regular schooling, education"
,
#15
"homework"
,
#16
"leisure & other education or training"
,
#17
"food preparation, cooking"
,
#18
"set table, wash/put away dishes"
,
#19
"cleaning"
,
#20
"laundry, ironing, clothing repair"
,
#21
"maintain home/vehicle, including collect fuel"
,
#22
"other domestic work"
,
#23
"purchase goods"
,
#24
"consume personal care services"
,
#25
"consume other services"
,
#26
"pet care (not walk dog)"
,
#27
"physical, medical child care"
,
#28
"teach, help with homework"
,
#29
"read to, talk or play with child"
,
#30
"supervise, accompany, other child care"
,
#31
"adult care"
,
#32
"voluntary, civic, organisational act"
,
#33
"worship and religion"
,
#34
"general out-of-home leisure"
,
#35
"attend sporting event"
,
#36
"cinema, theatre, opera, concert"
,
#37
"other public event, venue"
,
#38
"restaurant, café, bar, pub"
,
#39
"party, social event, gambling"
,
#40
"imputed time away from home"
,
#41
"general sport or exercise"
,
#42
"walking"
,
#43
"cycling"
,
#44
"other outside recreation"
,
#45
"gardening/pick mushrooms"
,
#46
"walk dogs"
,
#47
"receive or visit friends"
,
#48
"conversation (in person, phone)"
,
#49
"games (social & solitary)/other in-home social"
,
#50
"general indoor leisure"
,
#51
"art or music"
,
#52
"correspondence (not e-mail)"
,
#53
"knit, crafts or hobbies"
,
#54
"relax, think, do nothing"
,
#55
"read"
,
#56
"listen to music or other audio content"
,
#57
"listen to radio"
,
#58
"watch TV, video, DVD, streamed film"
,
#59
"computer games"
,
#60
"e-mail, surf internet, computing"
,
#61
"no second act, imputed or recorded transport"
,
#62
"travel to/from work"
,
#63
"education travel"
,
#64
"voluntary/civic/religious travel"
,
#65
"child/adult care travel"
,
#66
"shop, person/hhld care travel"
,
#67
"other travel"
,
#68
"no recorded activity"
#69
)
###
###
ba_MTUScreateIds
<-
function
(
dt
){
ba_MTUScreateIds
<-
function
(
dt
){
# create a unique pid & unique diary pid that will be unique across all years
# create a unique pid & unique diary pid that will be unique across all years
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment