Last updated: 2020-07-03
Checks: 7 0
Knit directory: 2020_LBPcausal/
This reproducible R Markdown analysis was created with workflowr (version 1.6.2). The Checks tab describes the reproducibility checks that were applied when the results were created. The Past versions tab lists the development history.
Great! Since the R Markdown file has been committed to the Git repository, you know the exact version of the code that produced these results.
Great job! The global environment was empty. Objects defined in the global environment can affect the analysis in your R Markdown file in unknown ways. For reproduciblity it’s best to always run the code in an empty environment.
The command set.seed(20200422)
was run prior to running the code in the R Markdown file. Setting a seed ensures that any results that rely on randomness, e.g. subsampling or permutations, are reproducible.
Great job! Recording the operating system, R version, and package versions is critical for reproducibility.
Nice! There were no cached chunks for this analysis, so you can be confident that you successfully produced the results during this run.
Great job! Using relative paths to the files within your workflowr project makes it easier to run your code on other machines.
Great! You are using Git for version control. Tracking code development and connecting the code version to the results is critical for reproducibility.
The results in this page were generated with repository version bd418c9. See the Past versions tab to see a history of the changes made to the R Markdown and HTML files.
Note that you need to be careful to ensure that all relevant files for the analysis have been committed to Git prior to generating the results (you can use wflow_publish
or wflow_git_commit
). workflowr only checks the R Markdown file, but you know if there are other scripts or data files that it depends on. Below is the status of the Git repository when the results were generated:
Ignored files:
Ignored: .Rhistory
Ignored: .Rproj.user/
Ignored: output/data_clean.xlsx
Unstaged changes:
Modified: analysis/2-mediation_early.Rmd
Modified: analysis/3-mediation_late.Rmd
Modified: analysis/4-mediation_early2late.Rmd
Note that any generated files, e.g. HTML, png, CSS, etc., are not included in this status report because it is ok for generated content to have uncommitted changes.
These are the previous versions of the repository in which changes were made to the R Markdown (analysis/1-preparation.Rmd
) and HTML (docs/1-preparation.html
) files. If you’ve configured a remote Git repository (see ?wflow_git_remote
), click on the hyperlinks in the table below to view the files as they were in that past version.
File | Version | Author | Date | Message |
---|---|---|---|---|
Rmd | f5b55d7 | bernard-liew | 2020-07-02 | removed function variable |
Rmd | 807f52c | bernard-liew | 2020-07-02 | added all possible change values |
Rmd | 127e9d3 | bernard-liew | 2020-06-11 | Original analysis |
# Helper packages
library (tidyverse)
library (tidyselect)
library (arsenal)
library (janitor)
library (magrittr)
# Import
library(readxl)
library (xlsx)
# Statistics
library (mice)
library (VIM)
library (corrr)
rm (list = ls())
dat <- read_excel("data/stops_dat.xlsx",
sheet = "data")
New names:
* `BASELINE Pain (leg)` -> `BASELINE Pain (leg)...8`
* `BASELINE Pain (leg)` -> `BASELINE Pain (leg)...9`
* `Orebro Q5` -> `Orebro Q5...36`
* `Orebro Q5` -> `Orebro Q5...37`
* `19: Reason pre-injury work status` -> `19: Reason pre-injury work status...63`
* ...
dat <- dat[c(1:300),]
cnames <- names (dat)
cnames_mod <- str_replace_all (tolower(cnames),
pattern = " ",
repl = "_")
names (dat) <- cnames_mod
df_orig <- dat
dummy_var <- grep ("dummy|0,|v_", cnames_mod, value = TRUE)
dat_sub <- dat[, !names (dat) %in% dummy_var]
(ncol (dat_sub) + length (dummy_var)) == length (names (dat))
[1] TRUE
df_orig_sub <- dat_sub
cnames_mod <- names (dat_sub)
# Time related variables
base_var <- grep ("baseline", cnames_mod, value = TRUE)
wk5_var <- grep ("5week|5_week", cnames_mod, value = TRUE)
wk10_var <- grep ("10week|10_week", cnames_mod, value = TRUE)
wk26_var <- grep ("26week|26_week", cnames_mod, value = TRUE)
wk52_var <- grep ("52week|52_week", cnames_mod, value = TRUE)
# Baseline variables
id_var<- tidyselect::vars_select (cnames_mod,
c("stops_id":
"baseline_date"))
orebro_var <- grep ("orebro", cnames_mod, value = TRUE)
fab_var <- grep ("fab", cnames_mod, value = TRUE)
work_var <- grep ("work|industry|occupation", cnames_mod, value = TRUE)
symptom_var <- grep ("symptom|next", cnames_mod, value = TRUE)
symptomLoc_var <- grep ("location", cnames_mod, value = TRUE)
episode_var <- grep ("episode", cnames_mod, value = TRUE)
sfbs_var <- grep ("sfbs", cnames_mod, value = TRUE)
other_var <- grep ("other_rx", cnames_mod, value = TRUE) # remove
treatment_var <- tidyselect::vars_select (cnames_mod,
c("treatment:_number_of_practitioners_seen_(all)":
"10:_rest_of_life"))
meds_var <- tidyselect::vars_select (cnames_mod, c("paracetamol":
"medication:_number_of_med_types_(all)")) # remove
misc_var <- tidyselect::vars_select (cnames_mod,
c("weight_(kg)":
"sa1_(code)"))
ses_var <- grep ("ses:", cnames_mod, value = TRUE)
personal_var <- tidyselect::vars_select (cnames_mod,
c("highest_level_of_education":
"number_of_smokes...316"))
symptHx_var <- tidyselect::vars_select (cnames_mod,
c("have_you_taken_any_tablets_for_your_back_today?":
"if_you_have_leg_and_back_symptoms,_are_they_related?...338"))
aggr_var <- grep ("agg|difficult|sorer", cnames_mod, value = TRUE)
ease_var <- grep ("ease|comfortable", cnames_mod, value = TRUE)
obj_curve_var <- tidyselect::vars_select (cnames_mod,
c("assessment:_obs:_standing-increased_lordosis":
"list_corresponding_to_worst_side"))
obj_rom_var <- tidyselect::vars_select (cnames_mod,
c("amt:_flexion_range_(cm)...462":
"range_of_side_with_most_limited_lf"))
obj_core_var <- tidyselect::vars_select (cnames_mod,
c("core_stability_in_standing":
"ta_low_tone"))
obj_sit_var <- grep ("sitting:", cnames_mod, value = TRUE)
obj_neuro_var <- tidyselect::vars_select (cnames_mod,
c("positive_slr":
"clinical_radiculopathy_with_no_mechanical_cause_on_imaging"))
aggr2_var <- tidyselect::vars_select (cnames_mod,
c("oswestry:_sitting_(p3)":
"repeated_movements:_reducible?"))
obj_core2_var <- grep ("multifidus", cnames_mod, value = TRUE)
obj_disc_var <- tidyselect::vars_select (cnames_mod,
c("regular_compression":
"degree_of_nerve_contact"))
redflag_var <- tidyselect::vars_select (cnames_mod,
c("constant_symptoms":
"general_health_state"))
euroqol_var <- grep ("euroqol", cnames_mod, value = TRUE)
dat_base_var <- dat_sub[, names (dat_sub) %in% base_var]
dat_base_var <- dat_base_var[, !names (dat_base_var) %in% c ("baseline_date",
"baseline_time_(0_weeks)",
"baseline_pain_(leg)...9")]
dat_base_var $working_at_baseline <- NULL
new.name1 <- paste0("base_", c ("osw",
"lbp",
"lp"))
new.name2 <- paste0 ("base_osw_q", c(1:10))
names(dat_base_var) <- c(new.name1, new.name2)
dat_wk5_var <- dat_sub [, names (dat_sub) %in% wk5_var]
dat_wk5_var <- dat_wk5_var [, !names (dat_wk5_var) %in% c ("5_week_outcome_date",
"5_weeks_(days_since_om_completed)",
"5_weeks_(weeks_since_om_completed)")]
new.name1 <- paste0("wk5_", c ("osw",
"lbp",
"lp",
"oreb"))
new.name2 <- paste0 ("wk5_oreb_q", c(4:24))
names(dat_wk5_var) <- c(new.name1, new.name2)
dat_wk10_var <- dat_sub [, names (dat_sub) %in% wk10_var]
dat_wk10_var <- dat_wk10_var [, !names (dat_wk10_var) %in% c ("10_week_outcome_date",
"10_weeks_(days_since_om_completed)",
"10_weeks_(weeks_since_om_completed)")]
new.name1 <- paste0("wk10_", c ("osw",
"lbp",
"lp",
"oreb"))
new.name2 <- paste0 ("wk10_oreb_q", c(4:24))
names(dat_wk10_var) <- c(new.name1, new.name2)
dat_wk26_var <- dat_sub [, names (dat_sub) %in% wk26_var]
dat_wk26_var <- dat_wk26_var [, !names (dat_wk26_var) %in% c ("26_week_outcome_date",
"26_weeks_(days_since_om_completed)",
"26_weeks_(weeks_since_om_completed)")]
new.name1 <- paste0("wk26_", c ("osw",
"lbp",
"lp",
"oreb"))
new.name2 <- paste0 ("wk26_oreb_q", c(4:24))
names(dat_wk26_var) <- c(new.name1, new.name2)
dat_wk52_var <- dat_sub [, names (dat_sub) %in% wk52_var]
dat_wk52_var <- dat_wk52_var [, !names (dat_wk52_var) %in% c ("52_week_outcome_date",
"52_weeks_(days_since_om_completed)",
"52_weeks_(weeks_since_om_completed)")]
new.name1 <- paste0("wk52_", c ("osw",
"lbp",
"lp",
"oreb"))
new.name2 <- paste0 ("wk52_oreb_q", c(4:24))
names(dat_wk52_var) <- c(new.name1, new.name2)
dat_id_var <- dat_sub [, names (dat_sub) %in% id_var]
dat_id_var <- dat_id_var [, !names (dat_id_var) %in% c ("baseline_date")]
names(dat_id_var) <- c("id", "rx_grp", "rx_subgrp")
orebro_var_sub <- orebro_var[!grepl("5w|10w|26w|52w|...37", orebro_var)]
dat_orebro_var <- dat_sub [, names (dat_sub) %in% orebro_var_sub ]
new.name1 <- c("base_oreb", paste0 ("base_oreb_q", c(4:24)))
names(dat_orebro_var) <- new.name1
dat_fab_var <- dat_sub [, names (dat_sub) %in% fab_var]
names(dat_fab_var) <- "base_fab"
work_var2 <- tidyselect::vars_select (work_var,
-c("19:_reason_pre-injury_work_status...64":
"working_other_than_nd_due_to_current__lbp",
"pre-inj_workers'_perceived_chance_of_working_at_6/12...72",
"workers'_perception_of_heavy_or_monotonous_work...75" ,
"pre-injury_workers'_sick_leave_duration_due_to_pain...78",
"pre-injury_house-keepers'_or_workers'_sick_leave_duration_due_to_pain...81",
"pre-injury_house-keepers'_or_workers'_sick_leave_duration_due_to_pain...80",
"ses:_index_of_education_and_occupation" ,
"occupation" ))
dat_work_var <- dat_sub [, names (dat_sub) %in% work_var2]
new.name1 <- c("work_status", "work_duty", "reas_not_work", "pre_work_status",
"pre_work_duty", "reas_pre_work_status", "pre_perc_work6mth",
"work", "prec_work", "work_statifac", "pre_sickleave_pain",
"pain_interfer", "industry", "hx_heavywork")
new.name2 <- paste0 ("base_", new.name1)
names(dat_work_var) <- new.name2
symptom_var2 <- tidyselect::vars_select (symptom_var ,
-c("duration_of_leg_symptoms...100":
"duration_of_symptoms:_longest_lx_or_leg" ,
"if_you_have_leg_and_back_symptoms,_are_they_related?...337",
"first_time_symptoms_started...422",
"time_of_day_symptoms_came_on...428",
"how_next_day...434" ,
"symptoms_following_day_much_worse_(p25)",
"constant_symptoms",
"night_symptoms" ))
dat_symptom_var <- dat_sub [, names (dat_sub) %in% symptom_var2 ]
new.name1 <- c("lbp_symptom", "leg_symptom", "lbp_duration", "leg_duration",
"freq_symptom", "back_leg_relation", "onset_symptom",
"time_symptom", "next_day_symptom", "pain_side")
new.name2 <- paste0 ("base_", new.name1)
names(dat_symptom_var) <- new.name2
symptomLoc_var2 <- tidyselect::vars_select (symptomLoc_var ,
-c("pain_location:_body_chart_-_psych...96",
"pain_location:_body_chart_-_psych...97",
"duration_of_leg_symptoms+pain_location_(body_chart)"))
dat_symptomLoc_var <- dat_sub [, names (dat_sub) %in% symptomLoc_var2]
new.name1 <- c("loc_antthigh_pain", "loc_belowknee_pain", "loc_leg_pain", "loc_body_ratio",
"loc_mostpain")
new.name2 <- paste0 ("base_", new.name1)
names(dat_symptomLoc_var) <- new.name2
episode_var2 <- tidyselect::vars_select (episode_var ,
-c( "previous_lbp_episodes:_<=4,_>4,_n_appl" ,
"not_the_first_ep_and_previous_lbp_episodes:_<=4,_>4,_n_appl"))
dat_episode_var <- dat_sub [, names (dat_sub) %in% episode_var2]
new.name1 <- c("first_episode", "first_episode_period")
new.name2 <- paste0 ("base_", new.name1)
names(dat_episode_var ) <- new.name2
dat_sfbs_var <- dat_sub [, names (dat_sub) %in% sfbs_var]
new.name1 <- c("freq_1", "freq_2", "freq_3", "freq_4", "freq_5",
"sciatica_freq_lbp", "sciatica_freq_nolbp", "bother_1",
"bother_2", "bother_3", "bother_4", "bother_5",
"sciatica_bother_lbp", "sciatica_bother_nolbp")
new.name2 <- paste0 ("base_sfbs_", new.name1)
names(dat_sfbs_var) <- new.name2
dat_other_var <- dat_sub [, names (dat_sub) %in% other_var]
treatment_var2 <- tidyselect::vars_select (treatment_var,
c( "total_number_of_treatments_across_all_types...228",
"8:_satisfaction_with_healthcare" ,
"9:_satisfaction_results",
"10:_rest_of_life" ))
dat_treatment_var <- dat_sub [, names (dat_sub) %in% treatment_var2]
new.name1 <- c("total_rx_no", "statisfac_healthcare", "statisfac_result", "rest_of_life")
new.name2 <- paste0 ("base_", new.name1)
names(dat_treatment_var) <- new.name2
treatment_var2 <- tidyselect::vars_select (treatment_var,
c( "total_number_of_treatments_across_all_types...228",
"8:_satisfaction_with_healthcare" ,
"9:_satisfaction_results",
"10:_rest_of_life" ))
dat_meds_var <- dat_sub [, names (dat_sub) %in% meds_var]
misc_var2 <- tidyselect::vars_select (misc_var,
c( "weight_(kg)",
"height_(cm)"))
dat_misc_var <- dat_sub [, names (dat_sub) %in% misc_var2]
new.name1 <- c("ht", "wt")
new.name2 <- paste0 ("base_", new.name1)
names(dat_misc_var) <- new.name2
dat_ses_var <- dat_sub [, names (dat_sub) %in% ses_var]
new.name1 <- c("ses_income", "ses_economic", "ses_occ", "ses_resource", "ses_advantage")
new.name2 <- paste0 ("base_", new.name1)
names(dat_ses_var) <- new.name2
symptHx_var2 <- tidyselect::vars_select (symptHx_var,
c("currently_having_a_flare_up?",
"p&n/n_below__waist_in_past_3_days"))
dat_symptHx_var <- dat_sub [, names (dat_sub) %in% symptHx_var2]
new.name1 <- c("current_flare", "pnn_below_waist")
new.name2 <- paste0 ("base_", new.name1)
names(dat_symptHx_var) <- new.name2
aggr_var2 <- tidyselect::vars_select (aggr_var,
-c("done_anything_to_agg?" ,
"agg:_lying_on_back...360",
"agg:_lying_on_stomach...362",
"what_is_most_difficult_about_getting_into_a_car?...370",
"what_is_most_difficult_about__sit_to_stand?",
"what_is_most_difficult_about_getting_into_a_car?...369",
"what_is_most_difficult_about_sit_to_stand?",
"sorer_to_lie_on_one_side_than_the_other?"))
dat_aggr_var <- dat_sub [, names (dat_sub) %in% aggr_var2]
new.name1 <- c( "walk", "stand", "sitfirm", "sitsoft", "lie_back", "lie_stom", "car", "sts",
"cough", "bend", "lift")
new.name2 <- paste0 ("base_agg_", new.name1)
names(dat_aggr_var) <- new.name2
ease_var2 <- tidyselect::vars_select (ease_var,
-c("most_comfortable_side_to_lie_on?...386" ,
"most_comfortable_side_to_lie_on?...387" ,
"ease:_lying_sore_side...416",
"ease:_lying_good_side...418",
"assessment:_obs:_standing-increased_lordosis",
"observation:_standing-increased_lordosis",
"decreased_lordosis...446",
"decreased_lordosis...447",
"movement_eases_sympt",
"night_pain+_movement_eases"))
dat_ease_var <- dat_sub [, names (dat_sub) %in% ease_var2]
new.name1 <- c("stand", "sitfirm", "sitsoft", "walk", "lie_back", "lie_back_bent", "lie_sore", "lie_good", "lie_stom")
new.name2 <- paste0 ("base_ease_", new.name1)
names(dat_ease_var) <- new.name2
obj_curve_var2 <- tidyselect::vars_select (obj_curve_var,
c("observation:_standing-increased_lordosis",
"decreased_lordosis...447" ,
"presence_of_a_list...452",
"list_direction...457" ,
"list_corresponding_to_worst_side" ))
dat_obj_curve_var <- dat_sub [, names (dat_sub) %in% obj_curve_var2]
new.name1 <- c("inc_lord", "dec_lord", "list", "list_dir", "list_dir_side")
new.name2 <- paste0 ("base_", new.name1)
names(dat_obj_curve_var) <- new.name2
obj_rom_var2 <- tidyselect::vars_select (obj_rom_var,
c("amt:_flexion_range_(cm)...462",
"amt:_extension_range_(cm)" ,
"amt:_llf_range_(cm)",
"amt:_rlf_range_(cm)"))
dat_obj_rom_var <- dat_sub [, names (dat_sub) %in% obj_rom_var2]
new.name1 <- c("flex", "ext", "llf", "rlf")
new.name2 <- paste0 ("base_rom_", new.name1)
names(dat_obj_rom_var) <- new.name2
obj_core_var2 <- tidyselect::vars_select (obj_core_var,
c("core_stability_in_standing" ,
"ta_quality_(lower_threshold)" ,
"ta_hypervig.",
"ta_low_tone"))
dat_obj_core_var <- dat_sub [, names (dat_sub) %in% obj_core_var2]
new.name1 <- c("core", "ta_qual", "ta_hyper", "ta_tone")
new.name2 <- paste0 ("base_", new.name1)
names(dat_obj_core_var) <- new.name2
obj_sit_var2 <- tidyselect::vars_select (obj_sit_var,
c("sitting:_degree_of_flexed_posture...495" ,
"sitting:_pain_response_to_correction...500"))
dat_obj_sit_var <- dat_sub [, names (dat_sub) %in% obj_sit_var2]
new.name1 <- c("sit_flex", "sit_pain_corr")
new.name2 <- paste0 ("base_", new.name1)
names(dat_obj_sit_var) <- new.name2
obj_neuro_var2 <- tidyselect::vars_select (obj_neuro_var,
c("positive_slr",
"positive_pkb",
"comparable_sensory_deficit...508",
"comparable_myo_deficit...509",
"comparable_knee_jerk_deficit",
"comparable_ankle_jerk_reflex",
"total_comparable_neuro_signs...513",
"clinical_radiculo-_pathy...515",
"clinical_radiculopathy_with_no_mechanical_cause_on_imaging" ))
dat_obj_neuro_var <- dat_sub [, names (dat_sub) %in% obj_neuro_var2]
new.name1 <- c("slr", "pkb", "sens_deficit", "myo_deficit", "knee_jerk_deficit", "ank_jerk_deficit", "total_neuro", "radiculo", "radiculo_image")
new.name2 <- paste0 ("base_", new.name1)
names(dat_obj_neuro_var) <- new.name2
aggr2_var2 <- tidyselect::vars_select (aggr2_var,
c("history_of_heavy_lifting_job_(p25)",
"discogenic_pain" ,
"discogenic_factors",
"repeated_movements:_reducible?"))
dat_aggr2_var <- dat_sub [, names (dat_sub) %in% aggr2_var2]
new.name1 <- c("hx_lift", "disc_pain", "disc_fac", "rep_movt_reduce")
new.name2 <- paste0 ("base_", new.name1)
names(dat_aggr2_var) <- new.name2
obj_core2_var2 <- tidyselect::vars_select (obj_core2_var,
-c("multifidus_substitution"))
dat_obj_core2_var <- dat_sub [, names (dat_sub) %in% obj_core2_var2 ]
new.name1 <- c("mf_tone", "mf_qual", "mf_hyper")
new.name2 <- paste0 ("base_", new.name1)
names(dat_obj_core2_var) <- new.name2
obj_disc_var2 <- tidyselect::vars_select (obj_disc_var,
c("regular_compression",
"palpation:_comparable_level_of_pain_and/or_stiffness"))
dat_obj_disc_var <- dat_sub [, names (dat_sub) %in% obj_disc_var2]
new.name1 <- c("reg_compress", "comparable_stiff")
new.name2 <- paste0 ("base_", new.name1)
names(dat_obj_disc_var) <- new.name2
redflag_var2 <- tidyselect::vars_select (redflag_var,
c("general_health_state"))
dat_redflag_var <- dat_sub [, names (dat_sub) %in% redflag_var2]
new.name1 <- c("gen_health")
new.name2 <- paste0 ("base_", new.name1)
names(dat_redflag_var) <- new.name2
euroqol_var2 <- tidyselect::vars_select (euroqol_var,
c("21:_euroqol:_mobility",
"euroqol:_person_appll_care",
"euroqol:_usual_activities",
"euroqol:_pain/discomfort",
"euroqol:_anxiety/depression",
"euroqol_utility_score_(uk_tto)"))
dat_euroqol_var <- dat_sub [, names (dat_sub) %in% euroqol_var2]
new.name1 <- c("mobility", "person_care", "activities", "pain", "anx_dep", "utility")
new.name2 <- paste0 ("base_euroq_", new.name1)
names(dat_euroqol_var) <- new.name2
df <- bind_cols(dat_id_var,
dat_misc_var,
dat_base_var,
dat_orebro_var,
dat_wk5_var,
dat_wk10_var,
dat_wk26_var,
dat_wk52_var,
dat_aggr_var,
dat_aggr2_var,
dat_ease_var,
dat_obj_core2_var,
dat_obj_core_var,
dat_obj_curve_var,
dat_obj_disc_var,
dat_obj_neuro_var,
dat_obj_rom_var,
dat_obj_sit_var,
dat_redflag_var,
dat_ses_var,
dat_sfbs_var,
dat_symptHx_var,
dat_symptom_var,
dat_symptomLoc_var,
dat_treatment_var,
dat_episode_var,
dat_fab_var,
dat_euroqol_var)
df_chr2num <- df %>%
dplyr::select_if(is.character) %>%
dplyr::select (matches ("wk|oreb|rom")) %>%
mutate_all(as.numeric)
Warning: NAs introduced by coercion
Warning: NAs introduced by coercion
Warning: NAs introduced by coercion
Warning: NAs introduced by coercion
Warning: NAs introduced by coercion
Warning: NAs introduced by coercion
df[names (df_chr2num)] <- df_chr2num
df_class <- map_chr(df, class)
df_num2chr <- df %>%
dplyr::select_if(is.numeric) %>%
dplyr::select (-matches ("id|ht|wt|time|osw|lbp|lp|osw|oreb|rom|gen|ses|sfbs|total_rx|fab|euroq|ratio|duration")) %>%
mutate_all(as.character)
df[names (df_num2chr)] <- df_num2chr
df_chr <- df %>%
dplyr::select_if(is.character)
df_num <- df %>%
dplyr::select_if(is.numeric)
tab1 <- tableby (~., data = df, digits = 2, digits.p = 2)
summary (tab1)
| | Overall (N=300) |
|:--------------------------------------|:-----------------:|
|**id** | |
| Mean (SD) | 3294.19 (1387.70) |
| Range | 1101.00 - 5903.00 |
|**rx_grp** | |
| advice | 34 (11.3%) |
| Advice | 110 (36.7%) |
| IndividualisedPhysio | 156 (52.0%) |
|**rx_subgrp** | |
| DHR | 54 (18.0%) |
| MFP | 8 (2.7%) |
| MTG | 64 (21.3%) |
| NRDP | 96 (32.0%) |
| RDP | 78 (26.0%) |
|**base_ht** | |
| N-Miss | 25 |
| Mean (SD) | 77.24 (16.62) |
| Range | 47.00 - 160.00 |
|**base_wt** | |
| N-Miss | 51 |
| Mean (SD) | 171.27 (10.90) |
| Range | 115.00 - 200.00 |
|**base_osw** | |
| Mean (SD) | 29.40 (12.33) |
| Range | 2.00 - 74.00 |
|**base_lbp** | |
| Mean (SD) | 5.36 (1.94) |
| Range | 0.00 - 10.00 |
|**base_lp** | |
| N-Miss | 40 |
| Mean (SD) | 4.67 (2.67) |
| Range | 0.00 - 10.00 |
|**base_osw_q1** | |
| Mean (SD) | 1.95 (0.91) |
| Range | 0.00 - 4.00 |
|**base_osw_q2** | |
| Mean (SD) | 0.72 (0.76) |
| Range | 0.00 - 4.00 |
|**base_osw_q3** | |
| Mean (SD) | 1.85 (1.18) |
| Range | 0.00 - 5.00 |
|**base_osw_q4** | |
| Mean (SD) | 0.95 (1.04) |
| Range | 0.00 - 3.00 |
|**base_osw_q5** | |
| Mean (SD) | 1.97 (1.01) |
| Range | 0.00 - 5.00 |
|**base_osw_q6** | |
| Mean (SD) | 1.64 (1.10) |
| Range | 0.00 - 5.00 |
|**base_osw_q7** | |
| Mean (SD) | 1.22 (0.77) |
| Range | 0.00 - 4.00 |
|**base_osw_q8** | |
| Mean (SD) | 1.49 (1.01) |
| Range | 0.00 - 5.00 |
|**base_osw_q9** | |
| Mean (SD) | 1.43 (1.03) |
| Range | 0.00 - 5.00 |
|**base_osw_q10** | |
| Mean (SD) | 1.51 (0.87) |
| Range | 0.00 - 5.00 |
|**base_oreb** | |
| Mean (SD) | 97.70 (24.53) |
| Range | 37.00 - 175.41 |
|**base_oreb_q4** | |
| Mean (SD) | 4.93 (2.37) |
| Range | 2.00 - 10.00 |
|**base_oreb_q5** | |
| N-Miss | 22 |
| Mean (SD) | 2.52 (1.94) |
| Range | 1.00 - 10.00 |
|**base_oreb_q6** | |
| N-Miss | 1 |
| Mean (SD) | 6.55 (1.59) |
| Range | 1.00 - 10.00 |
|**base_oreb_q7** | |
| N-Miss | 25 |
| Mean (SD) | 3.70 (3.22) |
| Range | 0.00 - 10.00 |
|**base_oreb_q8** | |
| N-Miss | 1 |
| Mean (SD) | 5.81 (1.95) |
| Range | 1.00 - 10.00 |
|**base_oreb_q9** | |
| N-Miss | 1 |
| Mean (SD) | 6.28 (1.97) |
| Range | 1.00 - 10.00 |
|**base_oreb_q10** | |
| Mean (SD) | 7.01 (2.26) |
| Range | 1.00 - 10.00 |
|**base_oreb_q11** | |
| N-Miss | 1 |
| Mean (SD) | 5.08 (2.27) |
| Range | 0.00 - 10.00 |
|**base_oreb_q12** | |
| Mean (SD) | 4.81 (2.59) |
| Range | 0.00 - 10.00 |
|**base_oreb_q13** | |
| N-Miss | 3 |
| Mean (SD) | 3.28 (3.00) |
| Range | 0.00 - 10.00 |
|**base_oreb_q14** | |
| N-Miss | 2 |
| Mean (SD) | 6.97 (2.32) |
| Range | 0.00 - 10.00 |
|**base_oreb_q15** | |
| N-Miss | 8 |
| Mean (SD) | 1.95 (3.20) |
| Range | 0.00 - 10.00 |
|**base_oreb_q16** | |
| N-Miss | 19 |
| Mean (SD) | 2.98 (2.82) |
| Range | 0.00 - 10.00 |
|**base_oreb_q17** | |
| Mean (SD) | 6.71 (2.63) |
| Range | 0.00 - 10.00 |
|**base_oreb_q18** | |
| N-Miss | 1 |
| Mean (SD) | 7.46 (2.38) |
| Range | 0.00 - 10.00 |
|**base_oreb_q19** | |
| N-Miss | 8 |
| Mean (SD) | 4.34 (3.34) |
| Range | 0.00 - 10.00 |
|**base_oreb_q20** | |
| Mean (SD) | 2.40 (2.23) |
| Range | 0.00 - 10.00 |
|**base_oreb_q21** | |
| Mean (SD) | 3.60 (2.98) |
| Range | 0.00 - 10.00 |
|**base_oreb_q22** | |
| Mean (SD) | 3.48 (2.32) |
| Range | 0.00 - 9.00 |
|**base_oreb_q23** | |
| Mean (SD) | 2.96 (2.33) |
| Range | 0.00 - 10.00 |
|**base_oreb_q24** | |
| Mean (SD) | 3.62 (2.51) |
| Range | 0.00 - 10.00 |
|**wk5_osw** | |
| N-Miss | 11 |
| Mean (SD) | 23.00 (13.84) |
| Range | 0.00 - 81.00 |
|**wk5_lbp** | |
| N-Miss | 8 |
| Mean (SD) | 3.48 (2.20) |
| Range | 0.00 - 10.00 |
|**wk5_lp** | |
| N-Miss | 47 |
| Mean (SD) | 3.00 (2.58) |
| Range | 0.00 - 10.00 |
|**wk5_oreb** | |
| N-Miss | 18 |
| Mean (SD) | 82.26 (27.37) |
| Range | 18.00 - 156.00 |
|**wk5_oreb_q4** | |
| N-Miss | 18 |
| Mean (SD) | 3.94 (2.24) |
| Range | 0.00 - 10.00 |
|**wk5_oreb_q5** | |
| N-Miss | 18 |
| Mean (SD) | 2.65 (2.14) |
| Range | 0.00 - 10.00 |
|**wk5_oreb_q6** | |
| N-Miss | 18 |
| Mean (SD) | 7.18 (1.82) |
| Range | 0.00 - 10.00 |
|**wk5_oreb_q7** | |
| N-Miss | 18 |
| Mean (SD) | 3.45 (3.09) |
| Range | 0.00 - 10.00 |
|**wk5_oreb_q8** | |
| N-Miss | 18 |
| Mean (SD) | 3.76 (2.37) |
| Range | 0.00 - 10.00 |
|**wk5_oreb_q9** | |
| N-Miss | 18 |
| Mean (SD) | 5.57 (2.13) |
| Range | 1.00 - 10.00 |
|**wk5_oreb_q10** | |
| N-Miss | 18 |
| Mean (SD) | 6.00 (2.38) |
| Range | 0.00 - 10.00 |
|**wk5_oreb_q11** | |
| N-Miss | 18 |
| Mean (SD) | 3.96 (2.53) |
| Range | 0.00 - 10.00 |
|**wk5_oreb_q12** | |
| N-Miss | 18 |
| Mean (SD) | 3.67 (2.75) |
| Range | 0.00 - 10.00 |
|**wk5_oreb_q13** | |
| N-Miss | 18 |
| Mean (SD) | 2.49 (2.84) |
| Range | 0.00 - 10.00 |
|**wk5_oreb_q14** | |
| N-Miss | 18 |
| Mean (SD) | 5.37 (2.87) |
| Range | 0.00 - 10.00 |
|**wk5_oreb_q15** | |
| N-Miss | 18 |
| Mean (SD) | 1.90 (3.12) |
| Range | 0.00 - 10.00 |
|**wk5_oreb_q16** | |
| N-Miss | 18 |
| Mean (SD) | 3.47 (2.55) |
| Range | 0.00 - 10.00 |
|**wk5_oreb_q17** | |
| N-Miss | 18 |
| Mean (SD) | 5.60 (2.97) |
| Range | 0.00 - 10.00 |
|**wk5_oreb_q18** | |
| N-Miss | 18 |
| Mean (SD) | 7.19 (2.65) |
| Range | 0.00 - 10.00 |
|**wk5_oreb_q19** | |
| N-Miss | 18 |
| Mean (SD) | 3.60 (3.19) |
| Range | 0.00 - 10.00 |
|**wk5_oreb_q20** | |
| N-Miss | 18 |
| Mean (SD) | 2.08 (2.13) |
| Range | 0.00 - 9.00 |
|**wk5_oreb_q21** | |
| N-Miss | 18 |
| Mean (SD) | 2.71 (2.75) |
| Range | 0.00 - 10.00 |
|**wk5_oreb_q22** | |
| N-Miss | 18 |
| Mean (SD) | 2.69 (2.23) |
| Range | 0.00 - 10.00 |
|**wk5_oreb_q23** | |
| N-Miss | 18 |
| Mean (SD) | 2.32 (2.25) |
| Range | 0.00 - 10.00 |
|**wk5_oreb_q24** | |
| N-Miss | 18 |
| Mean (SD) | 2.63 (2.56) |
| Range | 0.00 - 10.00 |
|**wk10_osw** | |
| N-Miss | 11 |
| Mean (SD) | 19.36 (14.11) |
| Range | 0.00 - 74.00 |
|**wk10_lbp** | |
| N-Miss | 8 |
| Mean (SD) | 3.11 (2.38) |
| Range | 0.00 - 10.00 |
|**wk10_lp** | |
| N-Miss | 47 |
| Mean (SD) | 2.46 (2.56) |
| Range | 0.00 - 10.00 |
|**wk10_oreb** | |
| N-Miss | 20 |
| Mean (SD) | 74.13 (28.09) |
| Range | 18.78 - 156.45 |
|**wk10_oreb_q4** | |
| N-Miss | 20 |
| Mean (SD) | 3.58 (2.08) |
| Range | 0.00 - 10.00 |
|**wk10_oreb_q5** | |
| N-Miss | 20 |
| Mean (SD) | 2.48 (2.15) |
| Range | 1.00 - 10.00 |
|**wk10_oreb_q6** | |
| N-Miss | 20 |
| Mean (SD) | 7.30 (2.08) |
| Range | 0.00 - 10.00 |
|**wk10_oreb_q7** | |
| N-Miss | 20 |
| Mean (SD) | 3.33 (3.06) |
| Range | 0.00 - 10.00 |
|**wk10_oreb_q8** | |
| N-Miss | 20 |
| Mean (SD) | 3.34 (2.41) |
| Range | 0.00 - 10.00 |
|**wk10_oreb_q9** | |
| N-Miss | 20 |
| Mean (SD) | 4.62 (2.26) |
| Range | 0.00 - 10.00 |
|**wk10_oreb_q10** | |
| N-Miss | 20 |
| Mean (SD) | 5.28 (2.65) |
| Range | 0.00 - 10.00 |
|**wk10_oreb_q11** | |
| N-Miss | 20 |
| Mean (SD) | 3.80 (2.60) |
| Range | 0.00 - 10.00 |
|**wk10_oreb_q12** | |
| N-Miss | 20 |
| Mean (SD) | 3.14 (2.78) |
| Range | 0.00 - 10.00 |
|**wk10_oreb_q13** | |
| N-Miss | 20 |
| Mean (SD) | 2.12 (2.76) |
| Range | 0.00 - 10.00 |
|**wk10_oreb_q14** | |
| N-Miss | 20 |
| Mean (SD) | 4.88 (3.08) |
| Range | 0.00 - 10.00 |
|**wk10_oreb_q15** | |
| N-Miss | 20 |
| Mean (SD) | 1.68 (2.89) |
| Range | 0.00 - 10.00 |
|**wk10_oreb_q16** | |
| N-Miss | 20 |
| Mean (SD) | 3.09 (2.49) |
| Range | 0.00 - 10.00 |
|**wk10_oreb_q17** | |
| N-Miss | 19 |
| Mean (SD) | 5.30 (2.93) |
| Range | 0.00 - 10.00 |
|**wk10_oreb_q18** | |
| N-Miss | 19 |
| Mean (SD) | 6.94 (2.82) |
| Range | 0.00 - 10.00 |
|**wk10_oreb_q19** | |
| N-Miss | 19 |
| Mean (SD) | 3.16 (3.01) |
| Range | 0.00 - 10.00 |
|**wk10_oreb_q20** | |
| N-Miss | 19 |
| Mean (SD) | 1.77 (2.22) |
| Range | 0.00 - 10.00 |
|**wk10_oreb_q21** | |
| N-Miss | 19 |
| Mean (SD) | 2.10 (2.58) |
| Range | 0.00 - 10.00 |
|**wk10_oreb_q22** | |
| N-Miss | 19 |
| Mean (SD) | 2.29 (2.33) |
| Range | 0.00 - 10.00 |
|**wk10_oreb_q23** | |
| N-Miss | 19 |
| Mean (SD) | 1.84 (2.15) |
| Range | 0.00 - 9.00 |
|**wk10_oreb_q24** | |
| N-Miss | 19 |
| Mean (SD) | 2.04 (2.22) |
| Range | 0.00 - 10.00 |
|**wk26_osw** | |
| N-Miss | 19 |
| Mean (SD) | 17.23 (14.79) |
| Range | 0.00 - 76.00 |
|**wk26_lbp** | |
| N-Miss | 16 |
| Mean (SD) | 2.95 (2.32) |
| Range | 0.00 - 10.00 |
|**wk26_lp** | |
| N-Miss | 55 |
| Mean (SD) | 2.28 (2.54) |
| Range | 0.00 - 10.00 |
|**wk26_oreb** | |
| N-Miss | 39 |
| Mean (SD) | 69.20 (31.81) |
| Range | 0.00 - 162.48 |
|**wk26_oreb_q4** | |
| N-Miss | 39 |
| Mean (SD) | 3.39 (2.20) |
| Range | 0.00 - 10.00 |
|**wk26_oreb_q5** | |
| N-Miss | 39 |
| Mean (SD) | 2.51 (2.20) |
| Range | 0.00 - 10.00 |
|**wk26_oreb_q6** | |
| N-Miss | 39 |
| Mean (SD) | 7.42 (3.06) |
| Range | 0.00 - 10.00 |
|**wk26_oreb_q7** | |
| N-Miss | 39 |
| Mean (SD) | 3.29 (3.03) |
| Range | 0.00 - 10.00 |
|**wk26_oreb_q8** | |
| N-Miss | 39 |
| Mean (SD) | 3.03 (2.51) |
| Range | 0.00 - 10.00 |
|**wk26_oreb_q9** | |
| N-Miss | 39 |
| Mean (SD) | 3.41 (2.32) |
| Range | 0.00 - 9.00 |
|**wk26_oreb_q10** | |
| N-Miss | 39 |
| Mean (SD) | 4.04 (2.60) |
| Range | 0.00 - 10.00 |
|**wk26_oreb_q11** | |
| N-Miss | 39 |
| Mean (SD) | 3.57 (2.78) |
| Range | 0.00 - 10.00 |
|**wk26_oreb_q12** | |
| N-Miss | 39 |
| Mean (SD) | 2.95 (2.67) |
| Range | 0.00 - 10.00 |
|**wk26_oreb_q13** | |
| N-Miss | 39 |
| Mean (SD) | 1.92 (2.52) |
| Range | 0.00 - 10.00 |
|**wk26_oreb_q14** | |
| N-Miss | 39 |
| Mean (SD) | 4.77 (3.23) |
| Range | 0.00 - 10.00 |
|**wk26_oreb_q15** | |
| N-Miss | 39 |
| Mean (SD) | 1.60 (2.80) |
| Range | 0.00 - 10.00 |
|**wk26_oreb_q16** | |
| N-Miss | 39 |
| Mean (SD) | 3.05 (2.49) |
| Range | 0.00 - 10.00 |
|**wk26_oreb_q17** | |
| N-Miss | 39 |
| Mean (SD) | 4.77 (3.06) |
| Range | 0.00 - 10.00 |
|**wk26_oreb_q18** | |
| N-Miss | 39 |
| Mean (SD) | 6.95 (3.03) |
| Range | 0.00 - 19.00 |
|**wk26_oreb_q19** | |
| N-Miss | 39 |
| Mean (SD) | 3.07 (3.04) |
| Range | 0.00 - 10.00 |
|**wk26_oreb_q20** | |
| N-Miss | 39 |
| Mean (SD) | 1.59 (2.08) |
| Range | 0.00 - 10.00 |
|**wk26_oreb_q21** | |
| N-Miss | 39 |
| Mean (SD) | 2.01 (2.62) |
| Range | 0.00 - 10.00 |
|**wk26_oreb_q22** | |
| N-Miss | 39 |
| Mean (SD) | 2.05 (2.23) |
| Range | 0.00 - 10.00 |
|**wk26_oreb_q23** | |
| N-Miss | 39 |
| Mean (SD) | 1.71 (2.24) |
| Range | 0.00 - 10.00 |
|**wk26_oreb_q24** | |
| N-Miss | 39 |
| Mean (SD) | 2.13 (2.33) |
| Range | 0.00 - 9.00 |
|**wk52_osw** | |
| N-Miss | 23 |
| Mean (SD) | 15.16 (14.56) |
| Range | 0.00 - 70.00 |
|**wk52_lbp** | |
| N-Miss | 22 |
| Mean (SD) | 2.68 (2.28) |
| Range | 0.00 - 9.00 |
|**wk52_lp** | |
| N-Miss | 59 |
| Mean (SD) | 2.03 (2.46) |
| Range | 0.00 - 9.00 |
|**wk52_oreb** | |
| N-Miss | 53 |
| Mean (SD) | 66.71 (33.35) |
| Range | 0.00 - 168.00 |
|**wk52_oreb_q4** | |
| N-Miss | 53 |
| Mean (SD) | 3.30 (2.20) |
| Range | 0.00 - 10.00 |
|**wk52_oreb_q5** | |
| N-Miss | 53 |
| Mean (SD) | 2.46 (2.19) |
| Range | 0.00 - 10.00 |
|**wk52_oreb_q6** | |
| N-Miss | 53 |
| Mean (SD) | 7.84 (3.47) |
| Range | 0.00 - 10.00 |
|**wk52_oreb_q7** | |
| N-Miss | 53 |
| Mean (SD) | 3.06 (3.02) |
| Range | 0.00 - 10.00 |
|**wk52_oreb_q8** | |
| N-Miss | 53 |
| Mean (SD) | 2.85 (2.50) |
| Range | 0.00 - 9.00 |
|**wk52_oreb_q9** | |
| N-Miss | 53 |
| Mean (SD) | 2.98 (2.40) |
| Range | 0.00 - 10.00 |
|**wk52_oreb_q10** | |
| N-Miss | 53 |
| Mean (SD) | 3.79 (2.89) |
| Range | 0.00 - 10.00 |
|**wk52_oreb_q11** | |
| N-Miss | 53 |
| Mean (SD) | 3.40 (2.69) |
| Range | 0.00 - 10.00 |
|**wk52_oreb_q12** | |
| N-Miss | 53 |
| Mean (SD) | 2.85 (2.72) |
| Range | 0.00 - 10.00 |
|**wk52_oreb_q13** | |
| N-Miss | 53 |
| Mean (SD) | 1.96 (2.64) |
| Range | 0.00 - 10.00 |
|**wk52_oreb_q14** | |
| N-Miss | 53 |
| Mean (SD) | 4.69 (3.45) |
| Range | 0.00 - 10.00 |
|**wk52_oreb_q15** | |
| N-Miss | 53 |
| Mean (SD) | 1.86 (3.11) |
| Range | 0.00 - 10.00 |
|**wk52_oreb_q16** | |
| N-Miss | 53 |
| Mean (SD) | 3.01 (2.53) |
| Range | 0.00 - 10.00 |
|**wk52_oreb_q17** | |
| N-Miss | 53 |
| Mean (SD) | 4.64 (3.20) |
| Range | 0.00 - 10.00 |
|**wk52_oreb_q18** | |
| N-Miss | 53 |
| Mean (SD) | 6.50 (3.17) |
| Range | 0.00 - 10.00 |
|**wk52_oreb_q19** | |
| N-Miss | 53 |
| Mean (SD) | 2.98 (3.02) |
| Range | 0.00 - 10.00 |
|**wk52_oreb_q20** | |
| N-Miss | 53 |
| Mean (SD) | 1.57 (2.17) |
| Range | 0.00 - 10.00 |
|**wk52_oreb_q21** | |
| N-Miss | 53 |
| Mean (SD) | 1.82 (2.56) |
| Range | 0.00 - 10.00 |
|**wk52_oreb_q22** | |
| N-Miss | 53 |
| Mean (SD) | 1.82 (2.18) |
| Range | 0.00 - 10.00 |
|**wk52_oreb_q23** | |
| N-Miss | 53 |
| Mean (SD) | 1.50 (2.09) |
| Range | 0.00 - 9.00 |
|**wk52_oreb_q24** | |
| N-Miss | 53 |
| Mean (SD) | 1.84 (2.35) |
| Range | 0.00 - 10.00 |
|**base_agg_walk** | |
| N-Miss | 22 |
| 0 | 187 (67.3%) |
| 1 | 56 (20.1%) |
| 2 | 25 (9.0%) |
| 3 | 9 (3.2%) |
| 4 | 1 (0.4%) |
|**base_agg_stand** | |
| N-Miss | 6 |
| 0 | 79 (26.9%) |
| 1 | 48 (16.3%) |
| 2 | 90 (30.6%) |
| 3 | 69 (23.5%) |
| 4 | 8 (2.7%) |
|**base_agg_sitfirm** | |
| N-Miss | 8 |
| 0 | 109 (37.3%) |
| 1 | 78 (26.7%) |
| 2 | 76 (26.0%) |
| 3 | 23 (7.9%) |
| 4 | 6 (2.1%) |
|**base_agg_sitsoft** | |
| N-Miss | 7 |
| 0 | 80 (27.3%) |
| 1 | 56 (19.1%) |
| 2 | 80 (27.3%) |
| 3 | 57 (19.5%) |
| 4 | 20 (6.8%) |
|**base_agg_lie_back** | |
| N-Miss | 7 |
| 0 | 94 (32.1%) |
| 1 | 38 (13.0%) |
| 2 | 41 (14.0%) |
| 3 | 18 (6.1%) |
| 4 | 2 (0.7%) |
| 5 | 100 (34.1%) |
|**base_agg_lie_stom** | |
| N-Miss | 6 |
| 0 | 73 (24.8%) |
| 1 | 33 (11.2%) |
| 2 | 47 (16.0%) |
| 3 | 29 (9.9%) |
| 4 | 15 (5.1%) |
| 5 | 97 (33.0%) |
|**base_agg_car** | |
| N-Miss | 7 |
| 0 | 63 (21.5%) |
| 1 | 90 (30.7%) |
| 2 | 87 (29.7%) |
| 3 | 39 (13.3%) |
| 4 | 14 (4.8%) |
|**base_agg_sts** | |
| N-Miss | 3 |
| 0 | 35 (11.8%) |
| 1 | 92 (31.0%) |
| 2 | 110 (37.0%) |
| 3 | 44 (14.8%) |
| 4 | 16 (5.4%) |
|**base_agg_cough** | |
| N-Miss | 1 |
| 0 | 138 (46.2%) |
| 1 | 72 (24.1%) |
| 2 | 43 (14.4%) |
| 3 | 27 (9.0%) |
| 4 | 19 (6.4%) |
|**base_agg_bend** | |
| N-Miss | 1 |
| 0 | 31 (10.4%) |
| 1 | 76 (25.4%) |
| 2 | 96 (32.1%) |
| 3 | 60 (20.1%) |
| 4 | 32 (10.7%) |
| 5 | 4 (1.3%) |
|**base_agg_lift** | |
| N-Miss | 1 |
| 0 | 21 (7.0%) |
| 1 | 67 (22.4%) |
| 2 | 94 (31.4%) |
| 3 | 65 (21.7%) |
| 4 | 50 (16.7%) |
| 5 | 2 (0.7%) |
|**base_hx_lift** | |
| no | 192 (64.0%) |
| yes | 108 (36.0%) |
|**base_disc_pain** | |
| 0 | 243 (81.0%) |
| 1 | 57 (19.0%) |
|**base_disc_fac** | |
| 1 | 3 (1.0%) |
| 2 | 17 (5.7%) |
| 3 | 35 (11.7%) |
| 4 | 66 (22.0%) |
| 5 | 52 (17.3%) |
| 6 | 47 (15.7%) |
| 7 | 38 (12.7%) |
| 8 | 32 (10.7%) |
| 9 | 10 (3.3%) |
|**base_rep_movt_reduce** | |
| 0 | 112 (37.3%) |
| 1 | 188 (62.7%) |
|**base_ease_stand** | |
| N-Miss | 8 |
| 0 | 42 (14.4%) |
| 1 | 250 (85.6%) |
|**base_ease_sitfirm** | |
| N-Miss | 9 |
| 0 | 126 (43.3%) |
| 1 | 165 (56.7%) |
|**base_ease_sitsoft** | |
| N-Miss | 8 |
| 0 | 60 (20.5%) |
| 1 | 232 (79.5%) |
|**base_ease_walk** | |
| N-Miss | 11 |
| 0 | 160 (55.4%) |
| 1 | 129 (44.6%) |
|**base_ease_lie_back** | |
| N-Miss | 8 |
| 0 | 168 (57.5%) |
| 1 | 124 (42.5%) |
|**base_ease_lie_back_bent** | |
| N-Miss | 15 |
| 0 | 208 (73.0%) |
| 1 | 77 (27.0%) |
|**base_ease_lie_sore** | |
| N-Miss | 10 |
| 0 | 57 (19.7%) |
| 1 | 233 (80.3%) |
|**base_ease_lie_good** | |
| N-Miss | 7 |
| 0 | 121 (41.3%) |
| 1 | 172 (58.7%) |
|**base_ease_lie_stom** | |
| N-Miss | 11 |
| 0 | 92 (31.8%) |
| 1 | 197 (68.2%) |
|**base_mf_tone** | |
| N-Miss | 4 |
| < 30% MVC | 159 (53.7%) |
| > 30% MVC | 80 (27.0%) |
| nil | 57 (19.3%) |
|**base_mf_qual** | |
| N-Miss | 4 |
| 0 | 86 (29.1%) |
| 1 | 210 (70.9%) |
|**base_mf_hyper** | |
| N-Miss | 4 |
| 0 | 60 (20.3%) |
| 1 | 236 (79.7%) |
|**base_core** | |
| N-Miss | 2 |
| fair | 93 (31.2%) |
| good | 11 (3.7%) |
| minimal | 159 (53.4%) |
| nil | 35 (11.7%) |
|**base_ta_qual** | |
| 0 | 24 (8.0%) |
| 1 | 276 (92.0%) |
|**base_ta_hyper** | |
| 0 | 126 (42.0%) |
| 1 | 174 (58.0%) |
|**base_ta_tone** | |
| 0 | 109 (36.3%) |
| 1 | 191 (63.7%) |
|**base_inc_lord** | |
| N-Miss | 2 |
| 0 | 212 (71.1%) |
| 1 | 62 (20.8%) |
| 2 | 24 (8.1%) |
|**base_dec_lord** | |
| N-Miss | 42 |
| 0 | 164 (63.6%) |
| 1 | 73 (28.3%) |
| 2 | 19 (7.4%) |
| 3 | 2 (0.8%) |
|**base_list** | |
| 0 | 268 (89.3%) |
| 1 | 27 (9.0%) |
| 2 | 5 (1.7%) |
|**base_list_dir** | |
| 0 | 268 (89.3%) |
| 1 | 21 (7.0%) |
| 2 | 11 (3.7%) |
|**base_list_dir_side** | |
| Mean (SD) | 0.95 (0.23) |
| Range | 0.00 - 1.00 |
|**base_reg_compress** | |
| N-Miss | 1 |
| 0 | 86 (28.8%) |
| 1 | 213 (71.2%) |
|**base_comparable_stiff** | |
| N-Miss | 1 |
| 0 | 165 (55.2%) |
| 1 | 134 (44.8%) |
|**base_slr** | |
| 0 | 64 (21.3%) |
| 1 | 236 (78.7%) |
|**base_pkb** | |
| 0 | 3 (1.0%) |
| 1 | 297 (99.0%) |
|**base_sens_deficit** | |
| 0 | 55 (18.3%) |
| 1 | 245 (81.7%) |
|**base_myo_deficit** | |
| 0 | 36 (12.0%) |
| 1 | 264 (88.0%) |
|**base_knee_jerk_deficit** | |
| 0 | 5 (1.7%) |
| 1 | 295 (98.3%) |
|**base_ank_jerk_deficit** | |
| 0 | 27 (9.0%) |
| 1 | 273 (91.0%) |
|**base_total_neuro** | |
| 0 | 75 (25.0%) |
| 1 | 225 (75.0%) |
|**base_radiculo** | |
| 0 | 73 (24.3%) |
| 1 | 227 (75.7%) |
|**base_radiculo_image** | |
| 0 | 30 (10.0%) |
| 1 | 270 (90.0%) |
|**base_rom_flex** | |
| N-Miss | 1 |
| Mean (SD) | 20.06 (16.99) |
| Range | 0.00 - 73.00 |
|**base_rom_ext** | |
| N-Miss | 2 |
| Mean (SD) | 62.21 (5.95) |
| Range | 43.50 - 78.00 |
|**base_rom_llf** | |
| N-Miss | 2 |
| Mean (SD) | 47.25 (5.85) |
| Range | 25.00 - 70.00 |
|**base_rom_rlf** | |
| N-Miss | 2 |
| Mean (SD) | 46.83 (6.15) |
| Range | 30.00 - 70.00 |
|**base_sit_flex** | |
| N-Miss | 3 |
| 0 | 51 (17.2%) |
| 1 | 155 (52.2%) |
| 2 | 86 (29.0%) |
| 3 | 5 (1.7%) |
|**base_sit_pain_corr** | |
| N-Miss | 46 |
| 0 | 64 (25.2%) |
| 1 | 138 (54.3%) |
| 2 | 52 (20.5%) |
|**base_gen_health** | |
| N-Miss | 5 |
| Mean (SD) | 63.44 (18.51) |
| Range | 6.00 - 99.00 |
|**base_ses_income** | |
| N-Miss | 3 |
| Mean (SD) | 1344.39 (278.67) |
| Range | 612.00 - 2329.00 |
|**base_ses_economic** | |
| N-Miss | 5 |
| Mean (SD) | 1018.29 (80.79) |
| Range | 733.00 - 1145.00 |
|**base_ses_occ** | |
| N-Miss | 5 |
| Mean (SD) | 1031.18 (91.19) |
| Range | 818.00 - 1224.00 |
|**base_ses_resource** | |
| N-Miss | 5 |
| Mean (SD) | 995.73 (85.69) |
| Range | 389.00 - 1180.00 |
|**base_ses_advantage** | |
| N-Miss | 5 |
| Mean (SD) | 1017.13 (79.92) |
| Range | 764.00 - 1160.00 |
|**base_sfbs_freq_1** | |
| N-Miss | 1 |
| Mean (SD) | 3.93 (1.44) |
| Range | 0.00 - 6.00 |
|**base_sfbs_freq_2** | |
| N-Miss | 1 |
| Mean (SD) | 2.95 (2.05) |
| Range | 0.00 - 6.00 |
|**base_sfbs_freq_3** | |
| N-Miss | 1 |
| Mean (SD) | 2.05 (1.99) |
| Range | 0.00 - 6.00 |
|**base_sfbs_freq_4** | |
| N-Miss | 1 |
| Mean (SD) | 1.40 (1.75) |
| Range | 0.00 - 6.00 |
|**base_sfbs_freq_5** | |
| N-Miss | 1 |
| Mean (SD) | 3.90 (1.57) |
| Range | 0.00 - 6.00 |
|**base_sfbs_sciatica_freq_lbp** | |
| Mean (SD) | 14.18 (6.13) |
| Range | 0.00 - 28.00 |
|**base_sfbs_sciatica_freq_nolbp** | |
| Mean (SD) | 10.26 (5.66) |
| Range | 0.00 - 24.00 |
|**base_sfbs_bother_1** | |
| N-Miss | 2 |
| Mean (SD) | 3.85 (1.40) |
| Range | 0.00 - 6.00 |
|**base_sfbs_bother_2** | |
| N-Miss | 2 |
| Mean (SD) | 2.89 (2.16) |
| Range | 0.00 - 6.00 |
|**base_sfbs_bother_3** | |
| N-Miss | 2 |
| Mean (SD) | 1.77 (1.93) |
| Range | 0.00 - 6.00 |
|**base_sfbs_bother_4** | |
| N-Miss | 2 |
| Mean (SD) | 1.33 (1.69) |
| Range | 0.00 - 6.00 |
|**base_sfbs_bother_5** | |
| N-Miss | 2 |
| Mean (SD) | 3.83 (1.59) |
| Range | 0.00 - 6.00 |
|**base_sfbs_sciatica_bother_lbp** | |
| Mean (SD) | 13.58 (6.19) |
| Range | 0.00 - 28.00 |
|**base_sfbs_sciatica_bother_nolbp** | |
| Mean (SD) | 9.76 (5.63) |
| Range | 0.00 - 24.00 |
|**base_current_flare** | |
| N-Miss | 5 |
| 0 | 124 (42.0%) |
| 1 | 171 (58.0%) |
|**base_pnn_below_waist** | |
| N-Miss | 6 |
| 0 | 134 (45.6%) |
| 1 | 160 (54.4%) |
|**base_lbp_symptom** | |
| no | 1 (0.3%) |
| yes | 299 (99.7%) |
|**base_leg_symptom** | |
| ant thigh | 23 (7.7%) |
| below knee | 126 (42.0%) |
| both | 17 (5.7%) |
| nil | 132 (44.0%) |
| no | 2 (0.7%) |
|**base_lbp_duration** | |
| N-Miss | 8 |
| Mean (SD) | 14.62 (6.54) |
| Range | 0.00 - 26.00 |
|**base_leg_duration** | |
| N-Miss | 25 |
| Mean (SD) | 10.64 (7.75) |
| Range | 0.00 - 26.00 |
|**base_freq_symptom** | |
| N-Miss | 27 |
| 0 | 133 (48.7%) |
| 1 | 71 (26.0%) |
| 2 | 69 (25.3%) |
|**base_back_leg_relation** | |
| N-Miss | 58 |
| 0 | 197 (81.4%) |
| 1 | 45 (18.6%) |
|**base_onset_symptom** | |
| 0 | 92 (30.7%) |
| 1 | 57 (19.0%) |
| 2 | 47 (15.7%) |
| 3 | 56 (18.7%) |
| n_appl | 48 (16.0%) |
|**base_time_symptom** | |
| 0 | 79 (26.3%) |
| 1 | 49 (16.3%) |
| 2 | 29 (9.7%) |
| 3 | 14 (4.7%) |
| n_appl | 129 (43.0%) |
|**base_next_day_symptom** | |
| 0 | 21 (7.0%) |
| 1 | 101 (33.7%) |
| 2 | 35 (11.7%) |
| 3 | 66 (22.0%) |
| n_appl | 77 (25.7%) |
|**base_pain_side** | |
| N-Miss | 2 |
| left | 83 (27.9%) |
| Left | 35 (11.7%) |
| n_appl | 74 (24.8%) |
| right | 77 (25.8%) |
| Right | 29 (9.7%) |
|**base_loc_antthigh_pain** | |
| 0 | 40 (13.3%) |
| 1 | 260 (86.7%) |
|**base_loc_belowknee_pain** | |
| 0 | 143 (47.7%) |
| 1 | 157 (52.3%) |
|**base_loc_leg_pain** | |
| 0 | 17 (5.7%) |
| 1 | 283 (94.3%) |
|**base_loc_body_ratio** | |
| Mean (SD) | 15.17 (9.86) |
| Range | 1.75 - 68.00 |
|**base_loc_mostpain** | |
| N-Miss | 41 |
| 0 | 169 (65.3%) |
| 1 | 41 (15.8%) |
| 2 | 3 (1.2%) |
| 3 | 23 (8.9%) |
| 4 | 16 (6.2%) |
| 5 | 7 (2.7%) |
|**base_total_rx_no** | |
| Mean (SD) | 8.00 (9.10) |
| Range | 0.00 - 57.00 |
|**base_statisfac_healthcare** | |
| N-Miss | 22 |
| 0 | 29 (10.4%) |
| 1 | 74 (26.6%) |
| 2 | 87 (31.3%) |
| 3 | 70 (25.2%) |
| 4 | 18 (6.5%) |
|**base_statisfac_result** | |
| N-Miss | 26 |
| 0 | 35 (12.8%) |
| 1 | 88 (32.1%) |
| 2 | 74 (27.0%) |
| 3 | 65 (23.7%) |
| 4 | 12 (4.4%) |
|**base_rest_of_life** | |
| N-Miss | 2 |
| 0 | 229 (76.8%) |
| 1 | 58 (19.5%) |
| 2 | 6 (2.0%) |
| 3 | 4 (1.3%) |
| 4 | 1 (0.3%) |
|**base_first_episode** | |
| N-Miss | 1 |
| 0 | 84 (28.1%) |
| 1 | 215 (71.9%) |
|**base_first_episode_period** | |
| N-Miss | 30 |
| 1 | 20 (7.4%) |
| 2 | 16 (5.9%) |
| 3 | 38 (14.1%) |
| 4 | 135 (50.0%) |
| 5 | 61 (22.6%) |
|**base_fab** | |
| Mean (SD) | 6.18 (2.06) |
| Range | 1.33 - 10.00 |
|**base_euroq_mobility** | |
| Mean (SD) | 1.51 (0.50) |
| Range | 1.00 - 2.00 |
|**base_euroq_person_care** | |
| Mean (SD) | 1.26 (0.44) |
| Range | 1.00 - 2.00 |
|**base_euroq_activities** | |
| Mean (SD) | 1.78 (0.51) |
| Range | 1.00 - 3.00 |
|**base_euroq_pain** | |
| Mean (SD) | 2.07 (0.37) |
| Range | 1.00 - 3.00 |
|**base_euroq_anx_dep** | |
| Mean (SD) | 1.47 (0.57) |
| Range | 1.00 - 3.00 |
|**base_euroq_utility** | |
| Mean (SD) | 0.61 (0.23) |
| Range | -0.18 - 1.00 |
df$rx_grp <- tolower(df$rx_grp )
df$rx_subgrp <- tolower(df$rx_subgrp)
df$base_leg_duration <- as.numeric(df$base_leg_duration)
df$base_loc_body_ratio <- as.numeric (df$base_loc_body_ratio)
df$base_pain_side <- tolower(df$base_pain_side)
df$base_core <- ifelse (df$base_core == "nil", NA, df$base_core)
df$base_mf_tone <- ifelse (df$base_mf_tone == "nil", NA, df$base_mf_tone)
df$base_leg_symptom <- ifelse (df$base_leg_symptom == "nil", "no", df$base_leg_symptom)
df$base_list_dir_side <- as.character(df$base_list_dir_side)
df_chr <- df %>%
dplyr::select_if(is.character) %>%
mutate_all(as.factor)
levels (df_chr$rx_grp) <- c ("advice", "individualisedphysio")
levels (df_chr$rx_subgrp) <- c ("dhr", "nrdp", "rdp", "mfp", "mtg" )
levels (df_chr$base_agg_walk) <-
levels (df_chr$base_agg_stand) <-
levels (df_chr$base_agg_sitfirm) <-
levels (df_chr$base_agg_sitsoft) <-
c("0", "1", "2", "3", "4") # 0 good, 4 bad
levels (df_chr$base_agg_lie_back) <-
levels (df_chr$base_agg_lie_stom) <-
levels (df_chr$base_agg_car) <-
levels (df_chr$base_agg_sts) <-
levels (df_chr$base_agg_cough) <-
levels (df_chr$base_agg_bend) <-
levels (df_chr$base_agg_lift) <-
c("0", "1", "2", "3", "4", "5") # 0 good, 5 bad
levels (df_chr$base_ease_stand) <-
levels (df_chr$base_ease_sitfirm) <-
levels (df_chr$base_ease_sitsoft) <-
levels (df_chr$base_ease_walk) <-
levels (df_chr$base_ease_lie_back) <-
levels (df_chr$base_ease_lie_back_bent) <-
levels (df_chr$base_ease_lie_sore) <-
levels (df_chr$base_ease_lie_good) <-
levels (df_chr$base_ease_lie_stom) <-
c("0", "1") # 0 good, 1 bad
levels (df_chr$base_hx_lift) <-
levels (df_chr$base_disc_pain) <-
levels (df_chr$base_rep_movt_reduce) <-
c("0", "1") # 0 yes, 1 no
levels (df_chr$base_disc_fac) <-
as.character (c(0:9))
levels (df_chr$base_core) <-
c("minimal", "fair", "good" )
levels (df_chr$base_ta_qual) <-
levels (df_chr$base_ta_hyper) <- # 0 yes, 1 no
levels (df_chr$base_ta_tone) <- # 0 yes, 1 no
levels (df_chr$base_mf_hyper) <- # 0 yes, 1 no
levels (df_chr$base_mf_qual) <- # 0 yes, 1 no
c("0", "1")
levels (df_chr$base_mf_tone) <- c("> 30% MVC", "< 30% MVC")
levels (df_chr$base_inc_lord) <- c("0", "1", "2") # 0 nil, 1 mild, 2 mod
levels (df_chr$base_dec_lord) <- c("0", "1", "2", "3") # 0 nil, 1 mild, 2 mod, 3 marked
levels (df_chr$base_list) <- c("0", "1", "2") # 0 nil, 1 mild, 2 mod
levels (df_chr$base_list_dir) <- c("0", "1", "2") # 0 na, 1 left, 2 right
levels (df_chr$base_reg_compress) <- c("0", "1") # 0 yes, 1 no
levels (df_chr$base_slr) <-
levels (df_chr$base_pkb) <-
levels (df_chr$base_sens_deficit) <-
levels (df_chr$base_myo_deficit)<-
levels (df_chr$base_knee_jerk_deficit) <-
levels (df_chr$base_ank_jerk_deficit) <-
levels (df_chr$base_total_neuro) <-
levels (df_chr$base_radiculo) <-
levels (df_chr$base_radiculo_image) <-
c("0", "1") # 0 yes, 1 no
levels (df_chr$base_sit_flex) <- c("0", "1", "2", "3") # 0 nil, 1 mild, 2 mod, 3 mark
levels (df_chr$base_sit_pain_corr) <- c("0", "1", "2") # 0 improve, 1 same, 2 worse
levels (df_chr$base_current_flare) <-
levels (df_chr$base_pnn_below_waist)
levels (df_chr$base_list_dir_side) <- c("0", "1") # 0 yes, 1 no
levels (df_chr$base_back_leg_relation) <- c("0", "1", "2") # 0 yes, 1 no
levels (df_chr$base_lbp_symptom) <- c("no", "yes")
levels (df_chr$base_leg_symptom) <- c("no", " ant thigh", "below knee", "both") # 0 deep, 1 superficial, 2 na # need to check
levels (df_chr$base_freq_symptom) <- c("0", "1", "2") # 0 <50%, 1 >50%, 2 constant
levels (df_chr$base_back_leg_relation) <- c("0", "1", "2") # 0 yes, 1 no, 2 na
levels (df_chr$base_onset_symptom) <-
levels (df_chr$base_time_symptom) <-
levels (df_chr$base_next_day_symptom) <- c("n_appl", "0", "1", "2", "3")
levels (df_chr$base_pain_side) <- c("n_appl", "left", "right")
levels (df_chr$base_loc_antthigh_pain) <-
levels (df_chr$base_loc_belowknee_pain) <-
levels (df_chr$base_loc_leg_pain) <-
c("0", "1") # 0 yes, 1 no
levels (df_chr$base_loc_mostpain) <-
c("0", "1", "2", "3", "4", "5") # 0 back, 1 buttock, 2 groin, 3 thigh, 4 leg, 5 foot
levels (df_chr$base_statisfac_healthcare) <-
levels (df_chr$base_statisfac_result) <-
levels (df_chr$base_rest_of_life) <- c("0", "1", "2", "3", "4") # 0 dissatistied 4 very satisfied
levels (df_chr$base_first_episode) <- c("0", "1") # 0 yes, 1 no
# 0 <1mth , 1 2-6mth, 2 6-12mth, 3 1-2yr, 4 >3yr, 5 na
levels (df_chr$base_first_episode_period) <- c("0", "1", "2", "3", "4", "5")
df2 <- df %>%
dplyr::select_if(is.numeric) %>%
bind_cols(df_chr)
var_keep1 <- !grepl ("osw_q|ses|sfbs|euroq|statisfac|hyper|total_rx|rest|first|fab", names (df2))
df3 <- df2 [, var_keep1 ]
saveRDS (df3, "output/df_clean.RDS")
xlsx::write.xlsx2 (df3, "output/data_clean.xlsx")
rm (list = ls())
df <- readRDS("output/df_clean.RDS")
df_sub <- df[, grepl ("id|rx_grp|rx_sub|oreb_q|osw|lbp|_lp", names (df))]
df_sub <- df_sub [, !grepl ("pain|dir", names (df_sub))]
# names (df_sub) [grepl ("oreb_q8", names (df_sub))] <-
# str_replace(names (df_sub) [grepl ("oreb_q8", names (df_sub))], "oreb_q8", "pain_pastwk")
names (df_sub) [grepl ("oreb_q11", names (df_sub))] <-
str_replace(names (df_sub) [grepl ("oreb_q11", names (df_sub))], "oreb_q11", "pain_cope_success")
names (df_sub) [grepl ("oreb_q12", names (df_sub))] <-
str_replace(names (df_sub) [grepl ("oreb_q12", names (df_sub))], "oreb_q12", "anx")
names (df_sub) [grepl ("oreb_q13", names (df_sub))] <-
str_replace(names (df_sub) [grepl ("oreb_q13", names (df_sub))], "oreb_q13", "depress")
names (df_sub) [grepl ("oreb_q14", names (df_sub))] <-
str_replace(names (df_sub) [grepl ("oreb_q14", names (df_sub))], "oreb_q14", "pain_persist")
# names (df_sub) [grepl ("oreb_q15", names (df_sub))] <-
# str_replace(names (df_sub) [grepl ("oreb_q15", names (df_sub))], "oreb_q15", "work_expect")
df_sub <- df_sub %>%
mutate (base_func = base_oreb_q20 + base_oreb_q21 + base_oreb_q22 + base_oreb_q23 ,
wk5_func = wk5_oreb_q20 + wk5_oreb_q21 + wk5_oreb_q22 + wk5_oreb_q23 ,
wk10_func = wk10_oreb_q20 + wk10_oreb_q21 + wk10_oreb_q22 + wk10_oreb_q23 ,
wk26_func = wk26_oreb_q20 + wk26_oreb_q21 + wk26_oreb_q22 + wk26_oreb_q23 ,
wk52_func = wk52_oreb_q20 + wk52_oreb_q21 + wk52_oreb_q22 + wk52_oreb_q23,
base_fear = base_oreb_q17 + base_oreb_q18 + base_oreb_q19,
wk5_fear = wk5_oreb_q17 + wk5_oreb_q18 + wk5_oreb_q19,
wk10_fear = wk10_oreb_q17 + wk10_oreb_q18 + wk10_oreb_q19,
wk26_fear = wk26_oreb_q17 + wk26_oreb_q18 + wk26_oreb_q19,
wk52_fear = wk52_oreb_q17 + wk52_oreb_q18 + wk52_oreb_q19) %>%
dplyr::select (-matches ("oreb")) %>%
dplyr::select (-matches ("func")) %>% # remove this as use oswestry as functional outcome
dplyr::select (id, rx_grp, rx_subgrp, matches ("base_"), matches ("wk5_"),
matches ("wk10_"), matches ("wk26_"), matches ("wk52_"))
missing_per_indv <- (rowSums(is.na(df_sub))/ ncol (df_sub)) * 100
missing_per_indv
[1] 2.222222 0.000000 0.000000 0.000000 0.000000 2.222222 0.000000
[8] 0.000000 0.000000 0.000000 0.000000 0.000000 0.000000 0.000000
[15] 2.222222 13.333333 0.000000 0.000000 0.000000 2.222222 0.000000
[22] 0.000000 0.000000 33.333333 0.000000 0.000000 11.111111 11.111111
[29] 0.000000 17.777778 0.000000 0.000000 0.000000 0.000000 0.000000
[36] 0.000000 2.222222 0.000000 0.000000 2.222222 11.111111 0.000000
[43] 0.000000 0.000000 0.000000 11.111111 0.000000 0.000000 0.000000
[50] 0.000000 0.000000 0.000000 0.000000 0.000000 0.000000 24.444444
[57] 0.000000 0.000000 0.000000 0.000000 28.888889 0.000000 11.111111
[64] 33.333333 11.111111 0.000000 0.000000 11.111111 11.111111 11.111111
[71] 0.000000 0.000000 0.000000 11.111111 0.000000 0.000000 11.111111
[78] 4.444444 0.000000 0.000000 11.111111 0.000000 22.222222 11.111111
[85] 53.333333 0.000000 0.000000 0.000000 11.111111 35.555556 0.000000
[92] 0.000000 0.000000 0.000000 0.000000 2.222222 0.000000 0.000000
[99] 71.111111 71.111111 0.000000 0.000000 0.000000 0.000000 2.222222
[106] 0.000000 22.222222 0.000000 0.000000 0.000000 0.000000 11.111111
[113] 22.222222 0.000000 0.000000 0.000000 51.111111 37.777778 11.111111
[120] 11.111111 11.111111 71.111111 2.222222 0.000000 0.000000 0.000000
[127] 0.000000 0.000000 22.222222 11.111111 0.000000 0.000000 35.555556
[134] 0.000000 0.000000 0.000000 0.000000 0.000000 11.111111 0.000000
[141] 11.111111 0.000000 0.000000 26.666667 11.111111 11.111111 28.888889
[148] 33.333333 8.888889 35.555556 0.000000 0.000000 11.111111 55.555556
[155] 0.000000 0.000000 11.111111 11.111111 22.222222 22.222222 17.777778
[162] 0.000000 0.000000 42.222222 11.111111 33.333333 0.000000 0.000000
[169] 0.000000 0.000000 0.000000 11.111111 0.000000 0.000000 0.000000
[176] 0.000000 0.000000 0.000000 0.000000 0.000000 17.777778 11.111111
[183] 0.000000 0.000000 0.000000 0.000000 13.333333 0.000000 51.111111
[190] 0.000000 22.222222 0.000000 0.000000 71.111111 13.333333 0.000000
[197] 11.111111 0.000000 0.000000 11.111111 11.111111 0.000000 0.000000
[204] 0.000000 11.111111 11.111111 11.111111 0.000000 0.000000 4.444444
[211] 17.777778 0.000000 0.000000 11.111111 22.222222 11.111111 64.444444
[218] 0.000000 0.000000 0.000000 0.000000 11.111111 0.000000 11.111111
[225] 0.000000 11.111111 0.000000 0.000000 0.000000 11.111111 0.000000
[232] 44.444444 2.222222 0.000000 0.000000 0.000000 11.111111 0.000000
[239] 11.111111 22.222222 73.333333 2.222222 0.000000 26.666667 13.333333
[246] 2.222222 0.000000 0.000000 17.777778 35.555556 0.000000 0.000000
[253] 11.111111 11.111111 0.000000 0.000000 0.000000 2.222222 22.222222
[260] 0.000000 0.000000 11.111111 0.000000 2.222222 17.777778 2.222222
[267] 13.333333 2.222222 0.000000 0.000000 11.111111 0.000000 11.111111
[274] 0.000000 0.000000 17.777778 11.111111 0.000000 0.000000 0.000000
[281] 11.111111 17.777778 0.000000 13.333333 11.111111 0.000000 0.000000
[288] 0.000000 0.000000 11.111111 0.000000 0.000000 0.000000 0.000000
[295] 11.111111 0.000000 0.000000 35.555556 13.333333 0.000000
df_sub2 <- df_sub [missing_per_indv < 50, ]
const.df <- df_sub2[,!grepl ("base|wk", names(df_sub2))]
base.df <- df_sub2[,grepl ("base_|duration|symptom", names(df_sub2))]
base.df <- base.df[,!grepl ("duration|symptom", names(base.df))]
wk5.df <- df_sub2[,grepl ("wk5_", names(df_sub2))]
wk10.df <- df_sub2[,grepl ("wk10_", names(df_sub2))]
wk26.df <- df_sub2[,grepl ("wk26_", names(df_sub2))]
wk52.df <- df_sub2[,grepl ("wk52_", names(df_sub2))]
wk5_base <- wk5.df - base.df
wk10_base <- wk10.df - base.df
wk26_base <- wk26.df - base.df
wk52_base <- wk52.df - base.df
wk10_wk5 <- wk10.df - wk5.df
wk26_wk5 <- wk26.df - wk5.df
wk52_wk5 <- wk52.df - wk5.df
wk26_wk10 <- wk26.df - wk10.df
wk52_wk10 <- wk52.df - wk10.df
wk52_wk26 <- wk52.df - wk26.df
df.list <- list (wk5_base,
wk10_base,
wk26_base,
wk52_base,
wk10_wk5,
wk26_wk5,
wk52_wk5,
wk26_wk10,
wk52_wk10,
wk52_wk26)
for (n in seq_along (df.list)){
df.list[[n]] <- df.list[[n]] %>%
mutate (grp = const.df$rx_grp,
subgrp = const.df$rx_subgrp,
id = const.df$id)
}
names (df.list) <- c("wk5_base",
"wk10_base",
"wk26_base",
"wk52_base",
"wk10_wk5",
"wk26_wk5",
"wk52_wk5",
"wk26_wk10",
"wk52_wk10",
"wk52_wk26")
saveRDS (df.list, "output/df_change.RDS")
sessionInfo()
R version 3.6.2 (2019-12-12)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 10 x64 (build 18363)
Matrix products: default
locale:
[1] LC_COLLATE=English_United Kingdom.1252
[2] LC_CTYPE=English_United Kingdom.1252
[3] LC_MONETARY=English_United Kingdom.1252
[4] LC_NUMERIC=C
[5] LC_TIME=English_United Kingdom.1252
attached base packages:
[1] grid stats graphics grDevices utils datasets methods
[8] base
other attached packages:
[1] corrr_0.4.2 VIM_5.1.1 data.table_1.12.8 colorspace_1.4-1
[5] mice_3.9.0 xlsx_0.6.3 readxl_1.3.1 magrittr_1.5
[9] janitor_2.0.1 arsenal_3.4.0 tidyselect_1.1.0 forcats_0.5.0
[13] stringr_1.4.0 dplyr_0.8.4 purrr_0.3.3 readr_1.3.1
[17] tidyr_1.0.0 tibble_3.0.1 ggplot2_3.3.2 tidyverse_1.3.0
[21] workflowr_1.6.2
loaded via a namespace (and not attached):
[1] nlme_3.1-142 fs_1.3.1 lubridate_1.7.4 httr_1.4.1
[5] rprojroot_1.3-2 tools_3.6.2 backports_1.1.5 R6_2.4.1
[9] DBI_1.1.0 nnet_7.3-14 withr_2.2.0 sp_1.4-2
[13] curl_4.3 compiler_3.6.2 git2r_0.27.1 cli_2.0.2
[17] rvest_0.3.5 xml2_1.2.2 scales_1.1.1 lmtest_0.9-37
[21] DEoptimR_1.0-8 robustbase_0.93-6 digest_0.6.23 foreign_0.8-72
[25] rmarkdown_2.3 rio_0.5.16 pkgconfig_2.0.3 htmltools_0.5.0
[29] highr_0.8 dbplyr_1.4.4 rlang_0.4.6 rstudioapi_0.11
[33] generics_0.0.2 zoo_1.8-8 jsonlite_1.6 zip_2.0.4
[37] car_3.0-8 Matrix_1.2-18 Rcpp_1.0.3 munsell_0.5.0
[41] fansi_0.4.0 abind_1.4-5 lifecycle_0.2.0 stringi_1.4.3
[45] whisker_0.4 yaml_2.2.1 snakecase_0.11.0 carData_3.0-4
[49] MASS_7.3-51.6 blob_1.2.1 promises_1.1.0 crayon_1.3.4
[53] lattice_0.20-38 splines_3.6.2 haven_2.2.0 xlsxjars_0.6.1
[57] hms_0.5.3 knitr_1.29 pillar_1.4.4 ranger_0.12.1
[61] boot_1.3-25 reprex_0.3.0 glue_1.3.1 evaluate_0.14
[65] laeken_0.5.1 modelr_0.1.8 vcd_1.4-7 vctrs_0.3.1
[69] httpuv_1.5.2 cellranger_1.1.0 gtable_0.3.0 assertthat_0.2.1
[73] xfun_0.15 openxlsx_4.1.5 broom_0.5.6 e1071_1.7-3
[77] later_1.0.0 survival_3.2-3 class_7.3-17 rJava_0.9-12
[81] ellipsis_0.3.1