Skip to content

Commit

Permalink
fix multiqc folder creation part 2
Browse files Browse the repository at this point in the history
  • Loading branch information
jdcla authored and jdcla committed Dec 2, 2024
1 parent 720cacd commit 4dc3e26
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 3 deletions.
2 changes: 1 addition & 1 deletion transcript_transformer/processing.py
Original file line number Diff line number Diff line change
Expand Up @@ -756,7 +756,7 @@ def create_multiqc_reports(df, out_prefix):
orf_biotypes = (
df.filter(pl.col("ORF_type") == "varRNA-ORF")["transcript_biotype"]
.value_counts()
.sort(pl.col("transcript_biotype").cast(pl.Enum(ORF_BIOTYPE_ORDER)))
.sort("count", descending=True)
)
with open(output, mode="a") as f:
orf_biotypes.write_csv(f, separator="\t", include_header=False)
Expand Down
10 changes: 8 additions & 2 deletions transcript_transformer/ribotie.py
Original file line number Diff line number Diff line change
Expand Up @@ -229,9 +229,15 @@ def main():
)
if df is not None:
csv_to_gtf(args.h5_path, df, out_prefix, args.exclude_annotated)
os.makedirs(f"{os.path.dirname(args.out_prefix)}/multiqc", exist_ok=True)
os.makedirs(
os.path.join(os.path.dirname(args.out_prefix), "multiqc"),
exist_ok=True,
)
create_multiqc_reports(
df, f"{os.path.dirname(args.out_prefix)}/multiqc/{ribo_set_str}"
df,
os.path.join(
os.path.dirname(args.out_prefix), "multiqc", ribo_set_str
),
)


Expand Down

0 comments on commit 4dc3e26

Please sign in to comment.