Mercurial > repos > greg > ideas
comparison ideas.xml @ 12:5b5733e09344 draft
Uploaded
author | greg |
---|---|
date | Thu, 10 Aug 2017 14:09:11 -0400 |
parents | 6f486284731d |
children | 3b3bf5196bbe |
comparison
equal
deleted
inserted
replaced
11:6f486284731d | 12:5b5733e09344 |
---|---|
4 <requirement type="package" version="2.26.0">bedtools</requirement> | 4 <requirement type="package" version="2.26.0">bedtools</requirement> |
5 <requirement type="package" version="332">ucsc-bedgraphtobigwig</requirement> | 5 <requirement type="package" version="332">ucsc-bedgraphtobigwig</requirement> |
6 <requirement type="package" version="332">ucsc-bedsort</requirement> | 6 <requirement type="package" version="332">ucsc-bedsort</requirement> |
7 <requirement type="package" version="332">ucsc-bigwigaverageoverbed</requirement> | 7 <requirement type="package" version="332">ucsc-bigwigaverageoverbed</requirement> |
8 <requirement type="package" version="1.2.0">ideas</requirement> | 8 <requirement type="package" version="1.2.0">ideas</requirement> |
9 <requirement type="package" version="1.3.0">r-optparse</requirement> | |
9 </requirements> | 10 </requirements> |
10 <command><![CDATA[ | 11 <command><![CDATA[ |
11 #import os | 12 #import os |
12 mkdir -p tmp && | 13 #set tmp_dir = 'tmp' |
13 mkdir -p prep_output && | 14 #set prep_output_dir = 'prep_output' |
15 #set ideas_input_dir = 'ideas_input' | |
16 #set ideas_matrix_input_file = $ideas_input_dir/r_matrix.txt | |
17 mkdir -p $prep_output_dir && | |
18 mkdir -p $ideas_input_dir && | |
14 ############################################## | 19 ############################################## |
15 ## Create the config file and prepare the data | 20 ## Create the config file and prepare the data |
16 ############################################## | 21 ############################################## |
17 #set input_type = $input_type_cond.input_type | 22 #set input_type = $input_type_cond.input_type |
18 cp '$build_config_file' 'config_file.txt' && | 23 cp '$build_config_file' 'config_file.txt' && |
51 -norm | 56 -norm |
52 #end if | 57 #end if |
53 ############################################## | 58 ############################################## |
54 ## Build the R matrix from the prepMat output | 59 ## Build the R matrix from the prepMat output |
55 ############################################## | 60 ############################################## |
56 #set r_matrix_input = None | |
57 #for f in $os.listdir('tmp'): | |
58 #if f.endswith('.bed.gz'): | |
59 #set r_matrix_input = $os.path.join('tmp', $f) | |
60 #end if | |
61 #end for | |
62 #assert $r_matrix_input is not None and $os.path.getsize($r_matrix_input) > 0, "Output file from prepMat is missing or empty." | |
63 && Rscript '$__tool_directory__/build_matrix.R' | 61 && Rscript '$__tool_directory__/build_matrix.R' |
64 -i $r_matrix_input | 62 -i $tmp_dir/*.bed.gz |
65 -o '%s.input' % $f | 63 -o $ideas_matrix_input_file |
66 -w 'tmp' | 64 -w $ideas_input_dir |
67 ############################################## | 65 ############################################## |
68 ## Run IDEAS on the R matrix | 66 ## Run IDEAS on the R matrix |
69 ############################################## | 67 ############################################## |
70 && ideas | 68 && ideas |
71 '$build_config_file' | 69 '$build_config_file' |
117 #set set_max_standard_dev = $set_max_standard_dev_cond.set_max_standard_dev | 115 #set set_max_standard_dev = $set_max_standard_dev_cond.set_max_standard_dev |
118 #if str($set_max_standard_dev) == 'yes': | 116 #if str($set_max_standard_dev) == 'yes': |
119 -maxerr $set_max_standard_dev_cond.max_standard_dev | 117 -maxerr $set_max_standard_dev_cond.max_standard_dev |
120 #end if | 118 #end if |
121 -thread \${GALAXY_SLOTS:-4} | 119 -thread \${GALAXY_SLOTS:-4} |
122 -o 'prep_output' | 120 -o $prep_output_dir |
123 && mv prep_output/*.state $output_state | 121 && mv $prep_output_dir/*.state $output_state |
124 && mv prep_output/*.para $output_para | 122 && mv $prep_output_dir/*.para $output_para |
125 && mv prep_output/*cluster $output_cluster | 123 && mv $prep_output_dir/*cluster $output_cluster |
126 ]]></command> | 124 ]]></command> |
127 <configfiles> | 125 <configfiles> |
128 <configfile name="build_config_file"><![CDATA[#for $input_items in $input_type_cond.input_repeat: | 126 <configfile name="build_config_file"><![CDATA[#for $input_items in $input_type_cond.input_repeat: |
129 ${input_items.cell_type_name} ${input_items.epigenetic_factor_name} ${input_items.input} | 127 ${input_items.cell_type_name} ${input_items.epigenetic_factor_name} ${input_items.input} |
130 #end for ]]></configfile> | 128 #end for ]]></configfile> |