@@ -157,46 +157,70 @@ rule context_phylogeny_plot:
157157 "../scripts/report/context_phylogeny_plot.R"
158158
159159
160- # rule allele_freq_phylogeny_data: # nj
161- # ...
162-
163-
164- # rule allele_freq_phylogeny_plot:
165- # ...
160+ rule allele_freq_tree_data :
161+ conda : "../envs/renv.yaml"
162+ params :
163+ use_bionj = config ["USE_BIONJ" ],
164+ ref_name = config ["ALIGNMENT_REFERENCE" ],
165+ input :
166+ dist = REPORT_DIR_TABLES / "distances.csv" ,
167+ output :
168+ tree = report (REPORT_DIR_TABLES / "allele_freq_tree.nwk" ),
169+ log :
170+ LOGDIR / "allele_freq_tree_data" / "log.txt"
171+ script :
172+ "../scripts/report/allele_freq_tree_data.R"
166173
167174
168- # rule time_signal_data: # tempest
169- # ...
175+ rule allele_freq_tree_plot :
176+ conda : "../envs/renv.yaml"
177+ params :
178+ design = config ["PLOTS" ],
179+ ref_name = config ["ALIGNMENT_REFERENCE" ],
180+ plot_height_mm = 119.4 ,
181+ plot_width_mm = 159.2 ,
182+ input :
183+ tree = report (REPORT_DIR_TABLES / "allele_freq_tree.nwk" ),
184+ study_fasta = OUTDIR / f"{ OUTPUT_NAME } .fasta" ,
185+ metadata = config ["METADATA" ],
186+ output :
187+ plot = report (REPORT_DIR_PLOTS / "allele_freq_tree.png" ),
188+ log :
189+ LOGDIR / "allele_freq_tree_plot" / "log.txt"
190+ script :
191+ "../scripts/report/allele_freq_tree_plot.R"
170192
171193
172- # rule time_signal_plot: # tempest
173- # ...
194+ rule time_signal_data :
195+ conda : "../envs/renv.yaml"
196+ params :
197+ ref_name = config ["ALIGNMENT_REFERENCE" ],
198+ input :
199+ tree = report (REPORT_DIR_TABLES / "allele_freq_tree.nwk" ),
200+ metadata = config ["METADATA" ],
201+ output :
202+ table = report (REPORT_DIR_TABLES / "time_signal.csv" ),
203+ json = REPORT_DIR_TABLES / "time_signal.json"
204+ log :
205+ LOGDIR / "time_signal_data" / "log.txt"
206+ script :
207+ "../scripts/report/time_signal_data.R"
174208
175209
176- rule phylo_plots :
210+ rule time_signal_plot :
177211 conda : "../envs/renv.yaml"
178212 params :
179213 design = config ["PLOTS" ],
180- ref_name = config ["ALIGNMENT_REFERENCE" ],
181- boot_th = 95 ,
182- alrt_th = 80 ,
183214 plot_height_mm = 119.4 ,
184215 plot_width_mm = 159.2 ,
185- use_bionj = config ["USE_BIONJ" ]
186216 input :
187- dist = REPORT_DIR_TABLES / f"distances.csv" ,
188- study_fasta = OUTDIR / f"{ OUTPUT_NAME } .fasta" ,
189- ml = OUTDIR / f"tree_context/{ OUTPUT_NAME } .treefile" ,
190- metadata = config ["METADATA" ]
217+ table = report (REPORT_DIR_TABLES / "time_signal.csv" ),
191218 output :
192- temest = report (REPORT_DIR_PLOTS / "figure_9.png" ),
193- tree = report (REPORT_DIR_PLOTS / "figure_8.png" ),
194- table = report (REPORT_DIR_TABLES / "figure_9.csv" ),
195- json = temp (OUTDIR / "stats.lm.json" )
219+ plot = report (REPORT_DIR_PLOTS / "time_signal.png" ),
196220 log :
197- LOGDIR / "phylo_plots " / "log.txt"
221+ LOGDIR / "time_signal_plot " / "log.txt"
198222 script :
199- "../scripts/report/phylo_plots .R"
223+ "../scripts/report/time_signal_plot .R"
200224
201225
202226rule evo_plots :
@@ -263,14 +287,14 @@ rule report:
263287 SNV_spike = report (REPORT_DIR_PLOTS / "figure_5b.png" ),
264288 volcano = report (REPORT_DIR_PLOTS / "figure_6.png" ),
265289 panel = report (REPORT_DIR_PLOTS / "figure_7.png" ),
266- tree = report (REPORT_DIR_PLOTS / "figure_8 .png" ),
267- temest = report (REPORT_DIR_PLOTS / "figure_9 .png" ),
290+ tree = report (REPORT_DIR_PLOTS / "allele_freq_tree .png" ),
291+ temest = report (REPORT_DIR_PLOTS / "time_signal .png" ),
268292 heat_table = report (REPORT_DIR_TABLES / "heatmap.csv" ),
269293 evo = report (REPORT_DIR_PLOTS / "figure_11.png" ),
270294 omega_plot = report (REPORT_DIR_PLOTS / "figure_12.png" ),
271295 freyja_ts = OUTDIR / "demixing" / "freyja_data" / "last_barcode_update.txt" ,
272296 value = REPORT_DIR_TABLES / "diversity.json" ,
273- stats_lm = OUTDIR / "stats.lm .json" ,
297+ stats_lm = REPORT_DIR_TABLES / "time_signal .json" ,
274298 stats_ml = REPORT_DIR_TABLES / "context_phylogeny.json" ,
275299 table = OUTDIR / "summary_table.csv" ,
276300 sum_nv = OUTDIR / "summary_nv.json" ,
0 commit comments