generated from opensafely/research-template
/
project.yaml
125 lines (103 loc) · 4.27 KB
/
project.yaml
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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
version: '3.0'
expectations:
population_size: 1000
actions:
generate_study_population_1:
run: cohortextractor:latest generate_cohort --study-definition study_definition --index-date-range "2019-09-01 to 2020-05-01 by month" --output-format feather
outputs:
highly_sensitive:
cohort: output/input_*.feather
generate_study_population_2:
run: cohortextractor:latest generate_cohort --study-definition study_definition --index-date-range "2020-06-01 to 2020-12-01 by month" --output-format feather
outputs:
highly_sensitive:
cohort: output/input*.feather
generate_study_population_3:
run: cohortextractor:latest generate_cohort --study-definition study_definition --index-date-range "2021-01-01 to 2021-07-01 by month" --output-format feather
outputs:
highly_sensitive:
cohort: output/inpu*.feather
check_EGFR:
run: python:latest python analysis/check_EGFR.py
needs: [join_ethnicity_region]
outputs:
moderately_sensitive:
counts: output/egfr_tabulation.csv
generate_study_population_ethnicity:
run: cohortextractor:latest generate_cohort --study-definition study_definition_ethnicity --output-format feather
outputs:
highly_sensitive:
cohort: output/input_ethnicity.feather
join_ethnicity_region:
run: python:latest python analysis/join_ethnicity_region.py
needs: [generate_study_population_1, generate_study_population_2, generate_study_population_3, generate_study_population_ethnicity]
outputs:
highly_sensitive:
cohort: output/inp*.feather
generate_study_population_lithium:
run: cohortextractor:latest generate_cohort --study-definition study_definition_lithium --index-date-range "2019-09-01 to 2021-07-01 by month" --output-format feather
outputs:
highly_sensitive:
cohort: output/input_lithium_*.feather
calculate_numerators:
run: python:latest python analysis/calculate_numerators.py
needs: [join_ethnicity_region]
outputs:
highly_sensitive:
cohort: output/indicator_e_f_*.feather
calculate_composite_indicators:
run: python:latest python analysis/composite_indicators.py
needs: [calculate_numerators, join_ethnicity_region]
outputs:
moderately_sensitive:
counts: output/*_composite_measure.csv
generate_measures:
run: cohortextractor:latest generate_measures --study-definition study_definition --output-dir=output
needs: [join_ethnicity_region]
outputs:
moderately_sensitive:
measure_csv: output/measure_*_rate.csv
check_asthma:
run: python:latest python analysis/check_asthma.py
needs: [generate_measures]
outputs:
moderately_sensitive:
csv: output/asthma_sum.csv
generate_measures_demographics:
run: python:latest python analysis/calculate_measures.py
needs: [calculate_numerators, join_ethnicity_region, generate_study_population_lithium]
outputs:
moderately_sensitive:
counts: output/indicator_measure_*.csv
measure_csv: output/measure*_rate.csv
generate_plots:
run: python:latest python analysis/plot_measures.py
needs: [generate_measures, generate_measures_demographics, calculate_composite_indicators]
outputs:
moderately_sensitive:
counts: output/plot_*.jpeg
quintile: output/quintile_10.csv
cusum:
run: python:latest python analysis/cusum.py
needs: [generate_measures, generate_measures_demographics]
outputs:
moderately_sensitive:
cusum: output/cusum_results.json
plot_cusum:
run: python:latest python analysis/plot_cusum.py
needs: [cusum, generate_measures, generate_measures_demographics]
outputs:
moderately_sensitive:
cusum: output/cusum_indicator_*.jpeg
alert: output/alerts_indicator_*.jpeg
generate_notebook:
run: jupyter:latest jupyter nbconvert /workspace/analysis/report.ipynb --execute --to html --template basic --output-dir=/workspace/output --ExecutePreprocessor.timeout=86400 --no-input
needs: [generate_plots]
outputs:
moderately_sensitive:
notebook: output/report.html
run_tests:
run: python:latest python -m pytest --junit-xml=output/pytest.xml --verbose
outputs:
moderately_sensitive:
log: output/pytest.xml