-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathfactor.R
59 lines (45 loc) · 1.38 KB
/
factor.R
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
# Association of age, gender, mental illness, rescue mode, injury severity
# and psychological support with accident circumstances and mental health
#
# This factors were described to be associated with e.g. PTSD in literature
# Yet, none of them is a strong marker
# tools -----
library(plyr)
library(tidyverse)
library(rlang)
library(stringi)
library(exda)
library(soucer)
library(furrr)
library(rstatix)
library(trafo)
library(clustTools)
library(ggtext)
library(MASS)
library(lmqc)
library(doParallel)
library(caret)
library(caretExtra)
insert_head()
select <- dplyr::select
source_all('./tools/tools.R',
message = TRUE,
crash = TRUE)
# analysis globals -------
insert_msg('Analysis globals')
fct_globals <- list()
fct_globals$variables <- ptsd$var_lexicon %>%
filter(type %in% c('characteristic', 'response'))
# analysis scripts --------
insert_msg('Analysis scripts')
c('./factor scripts/age.R',
'./factor scripts/gender.R',
'./factor scripts/mental_illness.R',
'./factor scripts/prior_trauma.R',
'./factor scripts/rescue.R',
'./factor scripts/severity.R',
'./factor scripts/support.R',
'./factor scripts/modeling.R') %>%
source_all(message = TRUE, crash = TRUE)
# END ------
insert_tail()