-
Notifications
You must be signed in to change notification settings - Fork 0
/
testing.R
48 lines (33 loc) · 1.09 KB
/
testing.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
# Univariable testing and correlation for factors found to be significantly
# associated with the TRP/KN and the PHE/TYR systems as indentified by
# linear modeling with backward elimination
# tools ------
library(plyr)
library(tidyverse)
library(trafo)
library(rlang)
library(exda)
library(soucer)
insert_head()
c('./tools/tools.R') %>%
source_all(message = TRUE, crash = TRUE)
# analysis globals ------
insert_msg('Analysis globals')
test_globals <- list()
test_globals$variables <-
list(trp = mod_eli$inference[c("trp", "kyn", "kyn_trp")],
tyr = mod_eli$inference[c("tyr", "phe_tyr")]) %>%
map(~map(.x,
filter,
p_value < 0.05,
variable != 'Intercept')) %>%
map(~map(.x, ~.x$variable)) %>%
map(reduce, union)
# analysis scripts -----
insert_msg('Analysis scripts')
c('./testing scripts/trp_system.R',
'./testing scripts/tyr_system.R',
'./testing scripts/result_tables.R') %>%
source_all(message = TRUE, crash = TRUE)
# END -----
insert_tail()