Mercurial > repos > mvdbeek > deseq_normalization
diff deseq_normalization.xml @ 0:557c3cdf5b0a draft default tip
planemo upload for repository https://bitbucket.org/drosofff/gedtools/
author | mvdbeek |
---|---|
date | Mon, 29 Jun 2015 05:50:30 -0400 |
parents | |
children |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/deseq_normalization.xml Mon Jun 29 05:50:30 2015 -0400 @@ -0,0 +1,49 @@ +<tool id="DESeq_normalization" name="DESeq Normalization" version="1.0.2"> + <description>of hit lists (geometric method)</description> + <requirements> + <requirement type="package" version="3.1.2">R</requirement> + <requirement type="package" version="2.14">biocbasics</requirement> + </requirements> + <command interpreter="Rscript"> $normalizationDESeq </command> + <inputs> + <param name="input" type="data" format="tabular" label="Hit lists of items"/> + </inputs> + <outputs> + <data name="output_factors" format="tabular" label="Normalization Factors (Geometric mean method)" /> + <data name="norm_hit_table" format="tabular" label="Normalized Hit Table (Geometric mean method)" /> + </outputs> + <tests> + <test> + <param name="input" value="counts.tab" ftype="tabular"/> + <output name="output_factors" file="norm_factors.tab" ftype="tabular"/> + <output name="norm_hit_table" file="norm_table.tab" ftype="tabular"/> + </test> + </tests> + <configfiles> + <configfile name="normalizationDESeq"> + ## Setup R error handling to go to stderr + options( show.error.messages=F, error = function () { cat( geterrmessage(), file=stderr() ); q( "no", 1, F ) } ) + suppressMessages(require(DESeq)) + countsTable = read.delim("${input}", header=TRUE, check.names=FALSE) + rownames( countsTable )= countsTable[,1] + countsTable= countsTable[ , -1 ] + conds = c(rep ("C", length(countsTable[1,])-1 ), "T") + cds = newCountDataSet( countsTable, conds ) + cds = estimateSizeFactors( cds ) + write.table (as.data.frame(sizeFactors(cds)), file="${output_factors}", row.names=TRUE, col.names=TRUE, quote= FALSE, dec = ".", sep = "\t", eol = "\n") + norm_table = as.data.frame(counts( cds, normalized=TRUE )) + norm_table = cbind(rownames(norm_table), norm_table) + colnames(norm_table) = c("gene", colnames(countsTable) ) + write.table (norm_table, file="${norm_hit_table}", row.names=FALSE, col.names=TRUE, quote= FALSE, dec = ".", sep = "\t", eol = "\n") + </configfile> + </configfiles> + <help> + +**What it does** + +DESeq Normalization Factors (geometic mean method) +and +Normalized hit lists + + </help> +</tool>