Skip to content

Commit f2b6f10

Browse files
committed
define rule to create visualization table with "tol" column
1 parent 8e2146a commit f2b6f10

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

src/depiction_targeted_preproc/workflow/rules/rules_panel.smk

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,20 @@ rule panel_standardized_full:
1515
"--output-panel-path {output.csv}"
1616

1717

18+
# TODO use this in the visualization steps everywhere
19+
rule panel_visualize_full:
20+
input:
21+
csv="{sample}/panels/full.csv",
22+
output:
23+
csv="{sample}/panels/full_visualize.csv",
24+
run:
25+
import polars as pl
26+
27+
# TODO this absolutely needs to be configurable too
28+
df = pl.read_csv(input.csv).with_columns(tol=pl.lit(0.25)).drop("type")
29+
df.write_csv(output.csv)
30+
31+
1832
rule panel_filter_calibration:
1933
input:
2034
csv="{sample}/panels/full.csv",

0 commit comments

Comments
 (0)