Mercurial > repos > greg > ideas
changeset 149:a80b76535243 draft
Uploaded
author | greg |
---|---|
date | Fri, 12 Jan 2018 11:24:30 -0500 |
parents | 0ba72d5ca209 |
children | 3762c27d820a |
files | ideas.xml |
diffstat | 1 files changed, 67 insertions(+), 60 deletions(-) [+] |
line wrap: on
line diff
--- a/ideas.xml Thu Jan 11 10:32:59 2018 -0500 +++ b/ideas.xml Fri Jan 12 11:24:30 2018 -0500 @@ -14,10 +14,11 @@ #set tmp_dir = "tmp" #set prep_input_config = "prep_input_config.txt" #set prep_output_config = "prep_output_config.txt" +#set specify_genomic_window = $specify_genomic_window_cond.specify_genomic_window +#set perform_training = $perform_training_cond.perform_training ############################################## ## Create the config file and prepare the data ############################################## -#set specify_genomic_window = $specify_genomic_window_cond.specify_genomic_window #if str($output_heatmaps) == "yes": mkdir '$output_pdf_dir' && #end if @@ -82,99 +83,94 @@ #end if #end for #for chrom, tup in $window_positions_by_chroms.items(): - && ideas - '$prep_output_config' - '$specify_genomic_window_cond.bed_input' - $hp - -inv $tup[0] $tup[1] + && Rscript '$__tool_directory__/ideas.R' + #if str($perform_training) == "yes": + --training_iterations $perform_training_cond.training_iterations + --training_windows $perform_training_cond.training_windows + #end if + --prep_output_config '$prep_output_config' + --windows_bed '$specify_genomic_window_cond.bed_input' + --hp $hp + --window_start $tup[0] + --window_end $tup[1] #if str($log2) != "0.0": - -log2 $log2 + --log2 $log2 #end if #if str($max_states) != "0.0": - -G $max_states + --max_states $max_states #end if #if str($initial_states) != "0": - -C $initial_states + --initial_states $initial_states #end if #if str($max_position_classes) != "0": - -P $max_position_classes + --max_position_classes $max_position_classes #end if #if str($max_cell_type_clusters) != "0": - -K $max_cell_type_clusters + --max_cell_type_clusters $max_cell_type_clusters #end if #if str($prior_concentration) != "0.0": - -A $prior_concentration + --prior_concentration $prior_concentration #end if - -sample $burnin_num $mcmc_num + --burnin_num $burnin_num + --mcmc_num $mcmc_num #if str($minerr) != "0.0": - -minerr $minerr + --minerr $minerr #end if #if str($maxerr) != "0.0": - -maxerr $maxerr + --maxerr $maxerr #end if - -rseed $rseed - -thread \${GALAXY_SLOTS:-4} - -o '$project_name.$chrom' + --rseed $rseed + --thread \${GALAXY_SLOTS:-4} + --project_name '$project_name.$chrom' + --save_ideas_log $save_ideas_log #if str($save_ideas_log) == "yes": - &>>'$output_log'; - if [[ $? -ne 0 ]]; then - exit 1; - fi - #else: - &>>ideas_log.txt; - if [[ $? -ne 0 ]]; then - cp ideas_log.txt '$output_txt_dir' - exit 1; - fi + --output_log '$output_log' #end if #end for #else: ############################################## ## Not using a genomic window bed file. ############################################## - && ideas - '$prep_output_config' - $tmp_dir/*.bed - $hp + && Rscript '$__tool_directory__/ideas.R' + #if str($perform_training) == "yes": + --training_iterations $perform_training_cond.training_iterations + --training_windows $perform_training_cond.training_windows + #end if + --prep_output_config '$prep_output_config' + --windows_bed $tmp_dir/*.bed + --hp $hp #if str($log2) != "0.0": - -log2 $log2 + --log2 $log2 #end if #if str($max_states) != "0.0": - -G $max_states + --max_states $max_states #end if #if str($initial_states) != "0": - -C $initial_states + --initial_states $initial_states #end if #if str($max_position_classes) != "0": - -P $max_position_classes + --max_position_classes $max_position_classes #end if #if str($max_cell_type_clusters) != "0": - -K $max_cell_type_clusters + --max_cell_type_clusters $max_cell_type_clusters #end if #if str($prior_concentration) != "0.0": - -A $prior_concentration + --prior_concentration $prior_concentration #end if - -sample $burnin_num $mcmc_num + --burnin_num $burnin_num + --mcmc_num $mcmc_num #if str($minerr) != "0.0": - -minerr $minerr + --minerr $minerr #end if #if str($maxerr) != "0.0": - -maxerr $maxerr + --maxerr $maxerr #end if - -rseed $rseed - -thread \${GALAXY_SLOTS:-4} - -o '$project_name' + --rseed $rseed + --thread \${GALAXY_SLOTS:-4} + --project_name '$project_name' + --save_ideas_log $save_ideas_log #if str($save_ideas_log) == "yes": - &>'$output_log'; - if [[ $? -ne 0 ]]; then - exit 1; - fi - #else: - &>ideas_log.txt; - if [[ $? -ne 0 ]]; then - cp ideas_log.txt '$output_txt_dir' - exit 1; - fi + --output_log '$output_log' #end if #end if && mv ./*.cluster '$output_txt_dir' @@ -214,6 +210,17 @@ #end if]]></configfile> </configfiles> <inputs> + <conditional name="perform_training_cond"> + <param name="perform_training" type="select" label="Perform training?"> + <option value="yes" selected="true">Yes</option> + <option value="no">No</option> + </param> + <when value="yes"> + <param name="training_iterations" type="integer" value="20" min="1" label="Number of training iterations"/> + <param name="training_windows" type="integer" value="10000" min="1" label="Number of randomly selected windows for training"/> + </when> + <when value="no"/> + </conditional> <conditional name="cell_type_epigenetic_factor_cond"> <param name="cell_type_epigenetic_factor" type="select" label="Set cell type and epigenetic factor names by"> <option value="extract" selected="true">extracting them from the selected input file names</option> @@ -247,7 +254,7 @@ <param name="project_name" type="text" value="myProject" label="Project name" help="Outputs will have this base name"> <validator type="empty_field"/> </param> - <param argument="-rseed" type="integer" value="1234" min="0" max="1000000" label="Seed for IDEAS model initialization" help="Zero value generates a random seed, and this seed will be different for each job run."/> + <param name="rseed" type="integer" value="1234" min="0" max="1000000" label="Seed for IDEAS model initialization" help="Zero value generates a random seed, and this seed will be different for each job run."/> <conditional name="specify_genomic_window_cond"> <param name="specify_genomic_window" type="select" label="Select Bed file that defines genomic windows on which to process the data"> <option value="no" selected="true">No</option> @@ -272,14 +279,14 @@ <param name="bed_input" type="data" format="bed" label="Bed file specifying the genomic windows"/> </when> </conditional> - <param argument="-bychr" type="boolean" truevalue="-bychr" falsevalue="" checked="False" label="Output chromosomes in separate files"/> + <param name="bychr" type="boolean" truevalue="true" falsevalue="" checked="False" label="Output chromosomes in separate files"/> <param name="reads_per_bp" type="select" display="radio" label="Calculate the signal in each genomic window using"> <option value="6" selected="true">mean</option> <option value="8">max</option> </param> <param name="blacklist_input" type="data" format="bed" optional="True" multiple="True" label="Select file(s) containing regions to exclude"/> - <param argument="-norm" type="boolean" truevalue="-norm" falsevalue="" checked="False" label="Standardize all datasets"/> - <param argument="-hp" type="boolean" truevalue="-hp" falsevalue="" checked="False" label="Discourage state transition across chromosomes"/> + <param name="norm" type="boolean" truevalue="true" falsevalue="" checked="False" label="Standardize all datasets"/> + <param name="hp" type="boolean" truevalue="true" falsevalue="" checked="False" label="Discourage state transition across chromosomes"/> <param name="log2" type="float" value="0" min="0" label="Use log2(x+number) transformation" help="Zero means no log2 transformation"/> <param name="max_states" type="float" value="0" min="0" label="Maximum number of states to be inferred" help="Zero sets the maximum to a large number"/> <param name="initial_states" type="integer" value="20" min="0" label="Initial number of states" help="Positive integer"/> @@ -291,8 +298,8 @@ <param name="minerr" type="float" value="0.5" min="0" label="Minimum standard deviation for the emission Gaussian distribution" help="Zero value results in the default: 0.5"/> <param name="maxerr" type="float" value="1000000" min="0" label="Maximum standard deviation for the emission Gaussian distribution" help="Zero sets the maximum to a large number"/> <param name="output_heatmaps" type="select" display="radio" label="Output heatmaps?"> - <option value="no" selected="true">No</option> - <option value="yes">Yes</option> + <option value="yes" selected="true">Yes</option> + <option value="no">No</option> </param> <param name="save_ideas_log" type="select" display="radio" label="Save IDEAS log in an additional history item"> <option value="no" selected="true">No</option>