changeset 0:3e07bfeb2bf5 draft

Uploaded
author spficklin
date Tue, 19 Nov 2019 23:20:18 +0000
parents
children b79f4ad134a4
files aurora_wgcna.xml
diffstat 1 files changed, 238 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/aurora_wgcna.xml	Tue Nov 19 23:20:18 2019 +0000
@@ -0,0 +1,238 @@
+<tool id="aurora_wgcna" name="WGCNA" version="1.0.0">
+    <description>
+        Identify gene co-expression network modules using WGCNA.
+    </description>
+    <requirements>
+        <requirement type="package" version="2.7.3">pandoc</requirement>
+        <requirement type="package" version="1.20.3">r-getopt</requirement>
+        <requirement type="package" version="1.12">r-rmarkdown</requirement>
+        <requirement type="package" version="1.8.4">r-plyr</requirement>
+        <requirement type="package" version="0.4">r-dt</requirement>
+        <requirement type="package" version="0.4.0">r-htmltools</requirement>
+        <requirement type="package" version="1.68">r-wgcna</requirement>
+    </requirements>
+    <stdio>
+        <regex match="Execution halted"
+               source="both"
+               level="fatal"
+               description="Execution halted." />
+        <regex match="Error in"
+               source="both"
+               level="fatal"
+               description="An undefined error occured, please check your intput carefully and contact your administrator." />
+        <regex match="Fatal error"
+               source="both"
+               level="fatal"
+               description="An undefined error occured, please check your intput carefully and contact your administrator." />
+    </stdio>
+    <command>
+        <![CDATA[
+        export TOOL_INSTALL_DIR='${__tool_directory__}' &&
+
+        Rscript '${__tool_directory__}/aurora_wgcna_render.R'
+            -e $expression_data
+            -s $min_cluster_size
+            -b $block_size
+            -j $hard_threshold
+            #if $trait_data
+              -t $trait_data
+              -c $sname_col
+            #end if
+            #if $height_cut
+              -h $height_cut
+            #end if
+            #if $power
+              -p $power
+            #end if
+            -l $render_log_file
+            -a $r_data
+            -k $gene_module_file
+            -w $network_edges_file
+            -g $gene_association_file
+            -m $module_association_file
+            -q $module_association_report
+            -r $network_construction_report
+        ]]>
+    </command>
+    <inputs>
+        <param
+          type="data"
+          name="expression_data"
+          format="csv"
+          optional="false"
+          label="Gene expression data"
+          help="The gene expression data is an n x m matrix where n rows are the genes, m columns are the samples and the elements represent gene expression levels (derived either from Microarray or RNA-Seq).  The matrix should be stored in a comma-separated (CSV) file and it must have a header. The gene names must appear as the first column of data in the file."
+        />
+        <param
+          type="float"
+          value=""
+          name="height_cut"
+          optional="true"
+          label="Outlier Dendrogram Cut Height"
+          help="When checking for outliers, WGCNA performs hierarchical clustering. The resulting dendrogram can be cut at the given height to remove outliers. If no value is provided a cut height will automatically be determined. Try running this tool first without providing a value. Return and set a value if the results are not adequate."
+        />
+        <param
+          type="integer"
+          value=""
+          name="power"
+          optional="true"
+          label="Power"
+          help="Prior to network construction, WGCNA recommends that the gene expression data is raised to a power. The exact power that should be used will be automatically determined. Try running this tool first without providing a value. Return and set a value if the results are not adequate."
+        />
+        <param
+          type="integer"
+          value="30"
+          name="min_cluster_size"
+          optional="false"
+          label="Minimum Module Size"
+          help="The minimum module size. Modules smaller than this will not be included in the network."
+        />
+        <param
+          type="integer"
+          value="5000"
+          min="1000"
+          max="10000"
+          name="block_size"
+          optional="false"
+          label="Block Size"
+          help="Constructing a network can use an extreme amount of memory if the number of genes is high. The block size enables WGCNA to divide the data into blocks of genes with similar expression reducing the amount of memory used. The block size indicates the maximum number of genes that can be used in a block. The total number of blocks used will be the total genes divided by this number (plus 1 for any remainder)."
+        />
+        <param
+          type="float"
+          value="0.5"
+          name="hard_threshold"
+          optional="false"
+          label="Hard Threshold"
+          min="0"
+          max="1"
+          help="While WGCNA uses a soft thresholding approach for finding modules and constructing gene similarity, when exporting the network for display as a graph a hard threshold is still required. For WGCNA, the threhshold is applied to the Euclidian distance between all genes. But, there is no set prescribed method to decide on a proper hard threshold value. Set a threshold now, then you can apply filters later (such as in Cytoscape) to remove low weighted edges if desired."
+        />
+        <param
+          type="data"
+          name="trait_data"
+          format="csv"
+          optional="true" 
+          label="Sample Annotation data"
+          help="The sample annotation data is an n x m matrix where n is the samples and m are the features such as experimental condition, biosample properties, traits or phenotype values.  The matrix should be stored in a comma-separated (CSV) file. It must have a header."
+        />
+        <param
+          type="integer"
+          value="1"
+          name="sname_col"
+          optional="true"
+          label="Sample Name Column Number"
+          help="The number of the column (starting from 1) in the sample annotation data file where the sample name column is found."
+        />
+    </inputs>
+    <outputs>
+        <data
+          name="network_construction_report"
+          format="html"
+          label="network_construction_report.html"
+        />
+        <data
+          name="gene_module_file"
+          format="csv"
+          label="gene_module_file.csv"
+        />
+        <data
+          name="network_edges_file"
+          format="tabular"
+          label="network_edges.txt"
+        />
+        <data
+          name="module_association_report"
+          format="html"
+          label="module_association_report.html">
+          <filter>trait_data != None</filter>
+        </data>
+        <data
+          name="gene_association_file"
+          format="csv"
+          label="gene_association.csv">
+          <filter>trait_data != None</filter>
+        </data>
+        <data
+          name="module_association_file"
+          format="csv"
+          label="module_association.csv">
+          <filter>trait_data != None</filter>
+        </data>
+        <data
+          name="render_log_file"
+          format="txt"
+          label="render_log_file"
+          hidden="true"
+        />
+        <data
+          name="r_data"
+          format="rdata"
+          label="aurora_wgcna.RData"
+          hidden="true"
+        />
+    </outputs>
+    <tests>
+      <test>
+          <param name='expression_data' value="LiverFemale3600.gem.csv"/>
+          <output name="gene_module_file" file="gene_module.csv"/>
+          <output name="network_edges_file" file="network_edges.txt"/>
+          <output name="network_construction_report" file="network_construction_report.html"/>
+        </test>
+        <test>
+          <param name='expression_data' value="LiverFemale3600.gem.csv"/>
+          <param name='trait_data' value="ClinicalTraits.csv"/>
+          <output name="gene_module_file" file="gene_module.csv"/>
+          <output name="network_edges_file" file="network_edges.txt"/>
+          <output name="gene_association_file" file="gene_association_file.csv"/>
+          <output name="module_association_file" file="module_association_file.csv"/>
+          <output name="module_association_report" file="module_association_report.html"/>
+          <output name="network_construction_report" file="network_construction_report.html"/>
+        </test>
+    </tests>
+    <help><![CDATA[
+      This tool is a wrapper for the WGCNA R library.  Please see the online
+      WGCNA tutorial for further details.
+      ]]>
+    </help>
+    <citations>
+        <citation type="bibtex">
+            @article{langfelder2008wgcna,
+            title={WGCNA: an R package for weighted correlation network analysis},
+            author={Langfelder, Peter and Horvath, Steve},
+            journal={BMC bioinformatics},
+            volume={9},
+            number={1},
+            pages={559},
+            year={2008},
+            publisher={BioMed Central}
+            }
+        </citation>
+        <citation type="bibtex">
+            @article{allaire2016rmarkdown,
+            title={rmarkdown: Dynamic Documents for R, 2016},
+            author={Allaire, J and Cheng, Joe and Xie, Yihui and McPherson, Jonathan and Chang, Winston and Allen, Jeff and Wickham, Hadley and Atkins, Aron and Hyndman, Rob},
+            journal={R package version 0.9},
+            volume={6},
+            year={2016}
+            }
+        </citation>
+        <citation type="bibtex">
+            @book{xie2015dynamic,
+            title={Dynamic Documents with R and knitr},
+            author={Xie, Yihui},
+            volume={29},
+            year={2015},
+            publisher={CRC Press}
+            }
+        </citation>
+        <citation  type="bibtex">
+            @misc{dt2016,
+            title = {DT: A Wrapper of the JavaScript Library 'DataTables'},
+            author = {Yihui Xie},
+            year = {2016},
+            note = {R package version 0.2},
+            url = {https://CRAN.R-project.org/package=DT},
+            }
+        </citation>
+    </citations>
+</tool>