Repository 'decoupler_pseudobulk'
hg clone https://toolshed.g2.bx.psu.edu/repos/ebi-gxa/decoupler_pseudobulk

Changeset 11:70a5c6f2408d (2024-10-25)
Previous changeset 10:f6040492b499 (2024-10-02) Next changeset 12:a559be56720c (2024-10-27)
Commit message:
planemo upload for repository https://github.com/ebi-gene-expression-group/container-galaxy-sc-tertiary/ commit f6c6b8e014c99101232dc75aa972a12fc640a4de
modified:
decoupler_pseudobulk.py
decoupler_pseudobulk.xml
b
diff -r f6040492b499 -r 70a5c6f2408d decoupler_pseudobulk.py
--- a/decoupler_pseudobulk.py Wed Oct 02 08:26:56 2024 +0000
+++ b/decoupler_pseudobulk.py Fri Oct 25 15:12:24 2024 +0000
[
@@ -503,6 +503,14 @@
         for condition in conditions:
             # remove any starting or trailing whitespaces from condition
             condition = condition.strip()
+            if condition not in adata.obs[obs_field].unique():
+                raise ValueError(
+                    f"Condition '{condition}' from contrast {contrast}"
+                    f" is not present in the "
+                    f"obs_field '{obs_field}' from the AnnData object."
+                    f"Possible values are: "
+                    f"{', '.join(adata.obs[obs_field].unique())}."
+                )
             # check the percentage of cells that express each gene
             # Filter the AnnData object based on the obs_field value
             adata_filtered = adata[adata.obs[obs_field] == condition]
b
diff -r f6040492b499 -r 70a5c6f2408d decoupler_pseudobulk.xml
--- a/decoupler_pseudobulk.xml Wed Oct 02 08:26:56 2024 +0000
+++ b/decoupler_pseudobulk.xml Fri Oct 25 15:12:24 2024 +0000
[
@@ -1,4 +1,4 @@
-<tool id="decoupler_pseudobulk" name="Decoupler pseudo-bulk" version="1.4.0+galaxy5" profile="20.05">
+<tool id="decoupler_pseudobulk" name="Decoupler pseudo-bulk" version="1.4.0+galaxy6" profile="20.05">
     <description>aggregates single cell RNA-seq data for running bulk RNA-seq methods</description>
     <requirements>
         <requirement type="package" version="1.4.0">decoupler</requirement>
@@ -103,10 +103,10 @@
         <data name="filter_by_expr_plot" format="png" label="${tool.name} on ${on_string}: Filter by Expression plot" from_work_dir="plots_output_dir/filter_by_expr.png">
             <filter>produce_plots</filter>
         </data>
-        <data name="genes_ignore_per_contrast_field" format="tabular" label="{tool.name} on ${on_string}: Genes to ignore by contrast field" from_work_dir="deseq_output_dir/genes_to_ignore_per_contrast_field.tsv">
+        <data name="genes_ignore_per_contrast_field" format="tabular" label="${tool.name} on ${on_string}: Genes to ignore by contrast field" from_work_dir="deseq_output_dir/genes_to_ignore_per_contrast_field.tsv">
             <filter>factor_fields</filter>
         </data>
-        <data name="genes_ignore_per_contrast" format="tabular" label="{tool.name} on ${on_string}: Genes to ignore by contrast" from_work_dir="plots_output_dir/genes_to_filter_by_contrast.tsv">
+        <data name="genes_ignore_per_contrast" format="tabular" label="${tool.name} on ${on_string}: Genes to ignore by contrast" from_work_dir="plots_output_dir/genes_to_filter_by_contrast.tsv">
             <filter>filter_per_contrast['filter'] == 'yes'</filter>
         </data>
     </outputs>