Mercurial > repos > kpbioteam > chipeakanno_annopeaks
comparison chipeakanno_annopeaks.xml @ 4:104882a2de00 draft default tip
"planemo upload for repository https://github.com/kpbioteam/chipeakanno_annopeaks commit 3af73b895c2dac2b8d87d1dec15204e5d30c709a-dirty"
author | kpbioteam |
---|---|
date | Sun, 23 Feb 2020 07:58:07 -0500 |
parents | 6f52c0dc56d4 |
children |
comparison
equal
deleted
inserted
replaced
3:6f52c0dc56d4 | 4:104882a2de00 |
---|---|
1 <tool id="chipeakanno_annopeaks" name="ChIPpeakAnno annoPeaks" version="0.1.0"> | 1 <tool id="chipeakanno_annopeaks" name="ChIPpeakAnno annoPeaks" version="0.1.0"> |
2 <description>annotate peaks by annoGR object in the given range</description> | 2 <description>annotate peaks by annoGR object in the given range</description> |
3 <requirements> | 3 <requirements> |
4 <requirement type="package" version="3.16.0-0">bioconductor-chippeakanno</requirement> | 4 <requirement type="package" version="3.20.0">bioconductor-chippeakanno</requirement> |
5 <requirement type="package" version="2.99.0-3">bioconductor-ensdb.hsapiens.v75</requirement> | 5 <requirement type="package" version="2.99.0">bioconductor-ensdb.hsapiens.v75</requirement> |
6 <requirement type="package" version="1.42.1-1">bioconductor-rtracklayer</requirement> | 6 <requirement type="package" version="1.46.0">bioconductor-rtracklayer</requirement> |
7 <requirement type="package" version="1.2.2">bioconductor-genomeinfodbdata</requirement> | |
7 </requirements> | 8 </requirements> |
8 <command detect_errors="exit_code"><![CDATA[ | 9 <command detect_errors="exit_code"><![CDATA[ |
9 Rscript '$chipeakanno_annopeaks_script' | 10 Rscript '$chipeakanno_annopeaks_script' |
10 ]]></command> | 11 ]]></command> |
11 <configfiles> | 12 <configfiles> |
12 <configfile name="chipeakanno_annopeaks_script"><![CDATA[ | 13 <configfile name="chipeakanno_annopeaks_script"><![CDATA[ |
13 require("ChIPpeakAnno", quietly = TRUE) | 14 require("ChIPpeakAnno", quietly = TRUE) |
14 require("EnsDb.Hsapiens.v75", quietly = TRUE) | 15 require("EnsDb.Hsapiens.v75", quietly = TRUE) |
15 require("rtracklayer", quietly = TRUE) | 16 require("rtracklayer", quietly = TRUE) |
17 require("GenomeInfoDbData", quietly = TRUE) | |
16 | 18 |
17 options(warn = -1) | 19 options(warn = -1) |
18 | 20 |
19 data <- read.table('$dmp') | 21 data <- read.table('$dmp',header=FALSE) |
20 | 22 |
21 peaks <- GRanges(seqnames = data[, 1], | 23 peaks <- GRanges(seqnames = data[, 1], |
22 ranges = IRanges | 24 ranges = IRanges |
23 (start = data[, 2], end = data[, 3]),score=data[, as.numeric('$score')]) | 25 (start = as.numeric(data[, 2]), end = as.numeric(data[, 3]), score = data[, as.numeric('$score')])) |
24 | 26 |
25 db <- toGRanges(EnsDb.Hsapiens.v75) | 27 db <- toGRanges(EnsDb.Hsapiens.v75, feature="gene") |
26 seqlevelsStyle(peaks) <- seqlevelsStyle(db) | 28 seqlevelsStyle(peaks) <- seqlevelsStyle(db) |
27 | 29 |
28 start <- as.numeric('$start') | 30 start <- as.numeric('$start') |
29 end <- as.numeric('$end') | 31 end <- as.numeric('$end') |
30 | 32 |
33 write.table(anno, file= '$tab', quote = FALSE, row.names = FALSE, sep = "\t") | 35 write.table(anno, file= '$tab', quote = FALSE, row.names = FALSE, sep = "\t") |
34 ]]> | 36 ]]> |
35 </configfile> | 37 </configfile> |
36 </configfiles> | 38 </configfiles> |
37 <inputs> | 39 <inputs> |
38 <param type="data" name="dmp" format="interval" label="Differentially Methylated Positions"/> | 40 <param type="data" name="dmp" format="bed" label="Differentially Methylated Positions"/> |
39 <param name="type" type="select" label="bindingType" help="Specifying the criteria to associate peaks with annotation e.g. startSite start position of the feature strand"> | 41 <param name="type" type="select" label="bindingType" help="Specifying the criteria to associate peaks with annotation e.g. startSite start position of the feature strand"> |
40 <option value="startSite">startSite</option> | 42 <option value="startSite">startSite</option> |
41 <option value="endSite">endSite</option> | 43 <option value="endSite">endSite</option> |
42 <option value="fullRange">fullRange</option> | 44 <option value="fullRange">fullRange</option> |
43 <option value="nearestBiDirectionalPromoters">nearestBiDirectionalPromoters</option> | 45 <option value="nearestBiDirectionalPromoters">nearestBiDirectionalPromoters</option> |
50 <outputs> | 52 <outputs> |
51 <data name="tab" format="tabular" label="Table of Annotated Peaks"/> | 53 <data name="tab" format="tabular" label="Table of Annotated Peaks"/> |
52 </outputs> | 54 </outputs> |
53 <tests> | 55 <tests> |
54 <test> | 56 <test> |
55 <param name="dmp" value="Differentially_Methylated_Regions.interval"/> | 57 <param name="dmp" value="Differentially_Methylated_Positions.bed"/> |
56 <param name="type" value="startSite"/> | 58 <param name="type" value="startSite"/> |
57 <param name="start" value="-5000"/> | 59 <param name="start" value="-5000"/> |
58 <param name="end" value="5000"/> | 60 <param name="end" value="5000"/> |
59 <param name="score" value="5"/> | 61 <param name="score" value="5"/> |
60 <output name="tab" file="annoTab.tabular"/> | 62 <output name="tab" file="annoTab.tabular"/> |