Mercurial > repos > iuc > samtools_view
comparison samtools_view.xml @ 8:a8d747577392 draft
"planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tool_collections/samtools/samtools_view commit e73e642259254253f71335ed1cbd738bb06d3346"
| author | iuc |
|---|---|
| date | Wed, 02 Sep 2020 19:28:45 +0000 |
| parents | 25ca025bc1c1 |
| children | be7c8e8a5d08 |
comparison
equal
deleted
inserted
replaced
| 7:25ca025bc1c1 | 8:a8d747577392 |
|---|---|
| 1 <tool id="samtools_view" name="Samtools view" version="@TOOL_VERSION@+galaxy1"> | 1 <tool id="samtools_view" name="Samtools view" version="@TOOL_VERSION@+galaxy2"> |
| 2 <description>- reformat, filter, or subsample SAM, BAM or CRAM</description> | 2 <description>- reformat, filter, or subsample SAM, BAM or CRAM</description> |
| 3 <macros> | 3 <macros> |
| 4 <import>macros.xml</import> | 4 <import>macros.xml</import> |
| 5 <token name="@REF_DATA@"> | 5 <token name="@REF_DATA@"> |
| 6 ## additional reference data | 6 ## additional reference data |
| 18 <param name="collapsecigar" type="boolean" argument="-B" truevalue="-B" falsevalue="" checked="false" label="Collapse backward CIGAR operation" help="Collapse the backward CIGAR operation." /> | 18 <param name="collapsecigar" type="boolean" argument="-B" truevalue="-B" falsevalue="" checked="false" label="Collapse backward CIGAR operation" help="Collapse the backward CIGAR operation." /> |
| 19 </section> | 19 </section> |
| 20 </xml> | 20 </xml> |
| 21 <xml name="output_format_selector"> | 21 <xml name="output_format_selector"> |
| 22 <conditional name="output_format"> | 22 <conditional name="output_format"> |
| 23 <param name="oformat" type="select" label="Output format"> | 23 <param name="oformat" type="select" label="Output format" |
| 24 help="Note on BAM output format: The tool will generate coordinate-sorted BAM, i.e., may change the order of reads compared to the input. For BAM input, select 'Same as input' to produce BAM output with the read order retained."> | |
| 25 <option value="input">Same as input</option> | |
| 24 <option value="sam">SAM</option> | 26 <option value="sam">SAM</option> |
| 25 <option value="bam" selected="True">BAM (-b)</option> | 27 <option value="bam" selected="True">BAM (-b)</option> |
| 26 <option value="cram">CRAM (-C)</option> | 28 <option value="cram">CRAM (-C)</option> |
| 27 </param> | 29 </param> |
| 30 <when value="input" /> | |
| 28 <when value="sam"> | 31 <when value="sam"> |
| 29 <yield /> | 32 <yield /> |
| 30 <param name="fmtopt" type="hidden" value="" /> | |
| 31 </when> | 33 </when> |
| 32 <when value="bam"> | 34 <when value="bam" /> |
| 33 <param name="fmtopt" type="hidden" value="-b" /> | 35 <when value="cram" /> |
| 34 </when> | |
| 35 <when value="cram"> | |
| 36 <param name="fmtopt" type="hidden" value="-C" /> | |
| 37 </when> | |
| 38 </conditional> | 36 </conditional> |
| 39 </xml> | 37 </xml> |
| 40 </macros> | 38 </macros> |
| 41 <expand macro="requirements"> | 39 <expand macro="requirements"> |
| 42 <requirement type="package">gawk</requirement> | 40 <requirement type="package">gawk</requirement> |
| 47 @ADDTHREADS@ | 45 @ADDTHREADS@ |
| 48 ## prepare reference data | 46 ## prepare reference data |
| 49 @PREPARE_FASTA_IDX@ | 47 @PREPARE_FASTA_IDX@ |
| 50 @PREPARE_IDX@ | 48 @PREPARE_IDX@ |
| 51 | 49 |
| 50 ## determine the output format flag to pass to samtools view | |
| 51 ## -c for count mode | |
| 52 ## -b to produce BAM-formatted output | |
| 53 ## -C to produce CRAM-formatted output | |
| 54 ## SAM is the default ouput format | |
| 55 #set $fmtopt = '' | |
| 56 #if str($mode.output_options.reads_report_type) == 'count': | |
| 57 #set $fmtopt = '-c' | |
| 58 #else: | |
| 59 #if str($mode.output_options.output_format.oformat) == 'bam': | |
| 60 #set $fmtopt = '-b' | |
| 61 #elif str($mode.output_options.output_format.oformat) == 'cram': | |
| 62 #set $fmtopt = '-C' | |
| 63 #elif str($mode.output_options.output_format.oformat) == 'input': | |
| 64 #if $input.is_of_type('bam'): | |
| 65 #set $fmtopt = '-b' | |
| 66 #elif $input.is_of_type('cram'): | |
| 67 #set $fmtopt = '-C' | |
| 68 #else: | |
| 69 ## input in SAM format, make sure to keep header if present | |
| 70 #set $fmtopt = '-h' | |
| 71 #end if | |
| 72 #end if | |
| 73 #end if | |
| 74 | |
| 52 #if str($mode.outtype) == 'header': | 75 #if str($mode.outtype) == 'header': |
| 53 ## call samtools view and be done | 76 ## call samtools view and be done |
| 54 samtools view | 77 samtools view |
| 55 -H ${mode.output_options.output_format.fmtopt} -o outfile | 78 -H $fmtopt -o outfile |
| 56 @REF_DATA@ | 79 @REF_DATA@ |
| 57 infile | 80 infile |
| 58 #else: | 81 #else: |
| 59 ## are filtering and/or subsampling in effect? | 82 ## are filtering and/or subsampling in effect? |
| 60 #set $with_filtering = False | 83 #set $with_filtering = False |
| 128 #if $input.is_of_type('sam') or $std_filters or $reg_filters: | 151 #if $input.is_of_type('sam') or $std_filters or $reg_filters: |
| 129 ## There is no index or we cannot use it because we are | 152 ## There is no index or we cannot use it because we are |
| 130 ## not dealing with all of the reads in the indexed | 153 ## not dealing with all of the reads in the indexed |
| 131 ## file. We have to do an extra pass over the input to | 154 ## file. We have to do an extra pass over the input to |
| 132 ## count the reads to subsample. | 155 ## count the reads to subsample. |
| 133 sample_fragment=`samtools view -c $std_filters infile $reg_filters | awk '{s=\$1} END {frac=${mode.subsample_config.subsampling_mode.target}/s; print(frac < 1 ? $seed+frac : ".0")}'` && | 156 sample_fragment=`samtools view -c $std_filters infile $reg_filters | awk '{s=\$1} END {frac=s/${mode.subsample_config.subsampling_mode.target}; print(frac > 1 ? $seed+1/frac : ".0")}'` && |
| 134 #else: | 157 #else: |
| 135 ## We can get the count of reads to subsample using | 158 ## We can get the count of reads to subsample using |
| 136 ## an inexpensive call to idxstats. | 159 ## an inexpensive call to idxstats. |
| 137 sample_fragment=`samtools idxstats infile | awk '{s+=\$4+\$3} END {frac=${mode.subsample_config.subsampling_mode.target}/s; print(frac < 1 ? $seed+frac : ".0")}'` && | 160 sample_fragment=`samtools idxstats infile | awk '{s+=\$4+\$3} END {frac=s/${mode.subsample_config.subsampling_mode.target}; print(frac > 1 ? $seed+1/frac : ".0")}'` && |
| 138 #end if | 161 #end if |
| 139 #end if | 162 #end if |
| 140 #end if | 163 #end if |
| 141 | 164 |
| 142 ## call samtools view | 165 ## call samtools view |
| 143 samtools view | 166 samtools view |
| 144 -@ \$addthreads | 167 -@ \$addthreads |
| 145 | 168 $fmtopt |
| 146 #if str($mode.output_options.reads_report_type) == 'count': | |
| 147 -c | |
| 148 #else: | |
| 149 ${mode.output_options.output_format.fmtopt} | |
| 150 #end if | |
| 151 | 169 |
| 152 ## filter options (except regions filter, which is the last parameter) | 170 ## filter options (except regions filter, which is the last parameter) |
| 153 $std_filters | 171 $std_filters |
| 154 | 172 |
| 155 #if $with_subsampling: | 173 #if $with_subsampling: |
| 302 <when value="fraction"> | 320 <when value="fraction"> |
| 303 <param name="factor" type="float" optional="False" value="1" min="1" label="Downsampling factor" help="The factor by which to downsample the input reads. A fraction of approx. 1/factor of the reads will be kept (default: 1 = no downsampling)." /> | 321 <param name="factor" type="float" optional="False" value="1" min="1" label="Downsampling factor" help="The factor by which to downsample the input reads. A fraction of approx. 1/factor of the reads will be kept (default: 1 = no downsampling)." /> |
| 304 <expand macro="seed_input" /> | 322 <expand macro="seed_input" /> |
| 305 </when> | 323 </when> |
| 306 <when value="target"> | 324 <when value="target"> |
| 307 <param name="target" type="integer" optional="False" min="0" value="" label="Target # of reads" help="Sets the approx. target number of reads to subsample." /> | 325 <param name="target" type="integer" optional="False" min="1" value="" label="Target # of reads" help="Sets the approx. target number of reads to subsample." /> |
| 308 <expand macro="seed_input" /> | 326 <expand macro="seed_input" /> |
| 309 </when> | 327 </when> |
| 310 </conditional> | 328 </conditional> |
| 311 </section> | 329 </section> |
| 312 <conditional name="output_options"> | 330 <conditional name="output_options"> |
| 388 <when input="mode.output_options.output_format.oformat" value="sam" format="sam" /> | 406 <when input="mode.output_options.output_format.oformat" value="sam" format="sam" /> |
| 389 <when input="mode.output_options.output_format.oformat" value="bam" format="bam" /> | 407 <when input="mode.output_options.output_format.oformat" value="bam" format="bam" /> |
| 390 <when input="mode.output_options.output_format.oformat" value="cram" format="cram" /> | 408 <when input="mode.output_options.output_format.oformat" value="cram" format="cram" /> |
| 391 </change_format> | 409 </change_format> |
| 392 </data> | 410 </data> |
| 393 <data name="outputcnt" format="txt" from_work_dir="outfile" label="${tool.name} on ${on_string}: Counts"> | 411 <data name="outputcnt" format="tabular" from_work_dir="outfile" label="${tool.name} on ${on_string}: Counts"> |
| 394 <filter>mode['outtype'] != 'header' and mode['output_options']['reads_report_type'] == 'count'</filter> | 412 <filter>mode['outtype'] != 'header' and mode['output_options']['reads_report_type'] == 'count'</filter> |
| 395 </data> | 413 </data> |
| 396 </outputs> | 414 </outputs> |
| 397 <tests> | 415 <tests> |
| 398 <!-- sam to bam (copied from the sam_to_bam tool) --> | 416 <!-- sam to bam (copied from the sam_to_bam tool) --> |
| 414 <param name="addref_select" value="history" /> | 432 <param name="addref_select" value="history" /> |
| 415 <param name="ref" ftype="fasta" dbkey="equCab2" value="chr_m.fasta" /> | 433 <param name="ref" ftype="fasta" dbkey="equCab2" value="chr_m.fasta" /> |
| 416 </conditional> | 434 </conditional> |
| 417 <output name="outputsam" ftype="bam" file="sam_to_bam_out3.bam" /> | 435 <output name="outputsam" ftype="bam" file="sam_to_bam_out3.bam" /> |
| 418 </test> | 436 </test> |
| 419 <!-- bam to cram + region filter (adapted from bam_to_cram tool)--> | 437 |
| 438 <!-- bam to cram --> | |
| 439 <test> | |
| 440 <param name="input" value="test.cram" ftype="cram" /> | |
| 441 <conditional name="addref_cond"> | |
| 442 <param name="addref_select" value="history" /> | |
| 443 <param name="ref" value="test.fa" /> | |
| 444 </conditional> | |
| 445 <output name="outputsam" file="test.bam" ftype="bam" /> | |
| 446 </test> | |
| 447 | |
| 448 <!-- within bam operations expected to result in sorting or not --> | |
| 449 <test> | |
| 450 <!-- sorted bam should always result in unmodifed output --> | |
| 451 <param name="input" ftype="bam" value="1_sort.bam" /> | |
| 452 <assert_command> | |
| 453 <not_has_text text="samtools sort" /> | |
| 454 </assert_command> | |
| 455 <output name="outputsam" ftype="bam" file="1_sort.bam" /> | |
| 456 </test> | |
| 457 <test> | |
| 458 <!-- sorted bam should always result in unmodifed output --> | |
| 459 <param name="input" ftype="bam" value="1_sort.bam" /> | |
| 460 <conditional name="mode"> | |
| 461 <conditional name="output_options"> | |
| 462 <conditional name="output_format"> | |
| 463 <param name="oformat" value="input" /> | |
| 464 </conditional> | |
| 465 </conditional> | |
| 466 </conditional> | |
| 467 <assert_command> | |
| 468 <not_has_text text="samtools sort" /> | |
| 469 </assert_command> | |
| 470 <output name="outputsam" ftype="bam" file="1_sort.bam" /> | |
| 471 </test> | |
| 472 <test> | |
| 473 <!-- qname_sorted.bam should get sorted during "conversion" to bam ... --> | |
| 474 <param name="input" ftype="qname_sorted.bam" value="1_sort_read_names.bam" /> | |
| 475 <assert_command> | |
| 476 <has_text text="samtools sort" /> | |
| 477 </assert_command> | |
| 478 <output name="outputsam" ftype="bam" file="1_sort.bam" /> | |
| 479 </test> | |
| 480 <test> | |
| 481 <!-- ... but should be emitted unmodifed when using input format --> | |
| 482 <param name="input" ftype="qname_sorted.bam" value="1_sort_read_names.bam" /> | |
| 483 <conditional name="mode"> | |
| 484 <conditional name="output_options"> | |
| 485 <conditional name="output_format"> | |
| 486 <param name="oformat" value="input" /> | |
| 487 </conditional> | |
| 488 </conditional> | |
| 489 </conditional> | |
| 490 <assert_command> | |
| 491 <not_has_text text="samtools sort" /> | |
| 492 </assert_command> | |
| 493 <output name="outputsam" ftype="qname_sorted.bam" file="1_sort_read_names.bam" /> | |
| 494 </test> | |
| 495 <test> | |
| 496 <!-- unsorted.bam should get sorted during "conversion" to bam ... --> | |
| 497 <param name="input" ftype="unsorted.bam" value="1_sort_read_names.bam" /> | |
| 498 <assert_command> | |
| 499 <has_text text="samtools sort" /> | |
| 500 </assert_command> | |
| 501 <output name="outputsam" ftype="bam" file="1_sort.bam" /> | |
| 502 </test> | |
| 503 <test> | |
| 504 <!-- ... ... but should be emitted unmodifed when using input format --> | |
| 505 <param name="input" ftype="unsorted.bam" value="1_sort_read_names.bam" /> | |
| 506 <conditional name="mode"> | |
| 507 <conditional name="output_options"> | |
| 508 <conditional name="output_format"> | |
| 509 <param name="oformat" value="input" /> | |
| 510 </conditional> | |
| 511 </conditional> | |
| 512 </conditional> | |
| 513 <assert_command> | |
| 514 <not_has_text text="samtools sort" /> | |
| 515 </assert_command> | |
| 516 <output name="outputsam" ftype="unsorted.bam" file="1_sort_read_names.bam" /> | |
| 517 </test> | |
| 518 | |
| 519 <!-- bam to sam + header options (adapted from bam_to_sam tool)--> | |
| 520 <test> | |
| 521 <param ftype="bam" name="input" value="bam_to_sam_in1.bam" /> | |
| 522 <conditional name="mode"> | |
| 523 <conditional name="output_options"> | |
| 524 <conditional name="output_format"> | |
| 525 <param name="oformat" value="sam" /> | |
| 526 <param name="with_header" value="true" /> | |
| 527 </conditional> | |
| 528 </conditional> | |
| 529 </conditional> | |
| 530 <output file="bam_to_sam_out1.sam" ftype="sam" name="outputsam" /> | |
| 531 </test> | |
| 532 <test> | |
| 533 <param ftype="bam" name="input" value="bam_to_sam_in1.bam" /> | |
| 534 <conditional name="mode"> | |
| 535 <param name="outtype" value="header" /> | |
| 536 <conditional name="output_options"> | |
| 537 <conditional name="output_format"> | |
| 538 <param name="oformat" value="sam" /> | |
| 539 </conditional> | |
| 540 </conditional> | |
| 541 </conditional> | |
| 542 <output file="bam_to_sam_out2.sam" ftype="sam" name="outputsam" /> | |
| 543 </test> | |
| 544 <test> | |
| 545 <param ftype="bam" name="input" value="bam_to_sam_in1.bam" /> | |
| 546 <conditional name="mode"> | |
| 547 <conditional name="output_options"> | |
| 548 <conditional name="output_format"> | |
| 549 <param name="oformat" value="sam" /> | |
| 550 <param name="with_header" value="false" /> | |
| 551 </conditional> | |
| 552 </conditional> | |
| 553 </conditional> | |
| 554 <output file="bam_to_sam_out3.sam" ftype="sam" name="outputsam" /> | |
| 555 </test> | |
| 556 | |
| 557 <!-- count alignments --> | |
| 420 <test> | 558 <test> |
| 421 <param name="input" value="test.bam" ftype="bam" /> | 559 <param name="input" value="test.bam" ftype="bam" /> |
| 560 <conditional name="mode"> | |
| 561 <param name="outtype" value="all_reads" /> | |
| 562 <conditional name="output_options"> | |
| 563 <param name="reads_report_type" value="count" /> | |
| 564 </conditional> | |
| 565 </conditional> | |
| 566 <output name="outputcnt" file="test_counts.tab" ftype="tabular" /> | |
| 567 </test> | |
| 568 | |
| 569 <!-- region filters --> | |
| 570 <test> | |
| 571 <param name="input" value="test.sam" ftype="sam" /> | |
| 422 <conditional name="mode"> | 572 <conditional name="mode"> |
| 423 <param name="outtype" value="selected_reads" /> | 573 <param name="outtype" value="selected_reads" /> |
| 424 <section name="filter_config"> | 574 <section name="filter_config"> |
| 425 <conditional name="cond_region"> | 575 <conditional name="cond_region"> |
| 426 <param name="select_region" value="no"/> | 576 <param name="select_region" value="no"/> |
| 436 <param name="addref_select" value="history" /> | 586 <param name="addref_select" value="history" /> |
| 437 <param name="ref" value="test.fa" /> | 587 <param name="ref" value="test.fa" /> |
| 438 </conditional> | 588 </conditional> |
| 439 <output name="outputsam" file="test.cram" ftype="cram" compare="sim_size" delta="250" /> | 589 <output name="outputsam" file="test.cram" ftype="cram" compare="sim_size" delta="250" /> |
| 440 </test> | 590 </test> |
| 441 <!-- count alignments --> | 591 <test> |
| 442 <test> | |
| 443 <param name="input" value="test.bam" ftype="bam" /> | 592 <param name="input" value="test.bam" ftype="bam" /> |
| 444 <conditional name="mode"> | |
| 445 <param name="outtype" value="all_reads" /> | |
| 446 <conditional name="output_options"> | |
| 447 <param name="reads_report_type" value="count" /> | |
| 448 </conditional> | |
| 449 </conditional> | |
| 450 <output name="outputcnt" file="test_counts.tab" ftype="txt" /> | |
| 451 </test> | |
| 452 <test> | |
| 453 <param name="input" value="test.sam" ftype="sam" /> | |
| 454 <conditional name="mode"> | 593 <conditional name="mode"> |
| 455 <param name="outtype" value="selected_reads" /> | 594 <param name="outtype" value="selected_reads" /> |
| 456 <section name="filter_config"> | 595 <section name="filter_config"> |
| 457 <conditional name="cond_region"> | 596 <conditional name="cond_region"> |
| 458 <param name="select_region" value="no"/> | 597 <param name="select_region" value="no"/> |
| 467 <conditional name="addref_cond"> | 606 <conditional name="addref_cond"> |
| 468 <param name="addref_select" value="history" /> | 607 <param name="addref_select" value="history" /> |
| 469 <param name="ref" value="test.fa" /> | 608 <param name="ref" value="test.fa" /> |
| 470 </conditional> | 609 </conditional> |
| 471 <output name="outputsam" file="test.cram" ftype="cram" compare="sim_size" delta="250" /> | 610 <output name="outputsam" file="test.cram" ftype="cram" compare="sim_size" delta="250" /> |
| 611 </test> | |
| 612 <test> | |
| 613 <param name="input" value="test2.cram" dbkey="equCab2" ftype="cram" /> | |
| 614 <conditional name="mode"> | |
| 615 <param name="outtype" value="selected_reads" /> | |
| 616 <section name="filter_config"> | |
| 617 <conditional name="cond_region"> | |
| 618 <param name="select_region" value="no"/> | |
| 619 </conditional> | |
| 620 </section> | |
| 621 <conditional name="output_options"> | |
| 622 <conditional name="output_format"> | |
| 623 <param name="oformat" value="bam" /> | |
| 624 </conditional> | |
| 625 </conditional> | |
| 626 </conditional> | |
| 627 <conditional name="addref_cond"> | |
| 628 <param name="addref_select" value="cached" /> | |
| 629 <param name="ref" value="equCab2chrM" /> | |
| 630 </conditional> | |
| 631 <output name="outputsam" file="sam_to_bam_out2.bam" ftype="bam" /> | |
| 472 </test> | 632 </test> |
| 473 <test> | 633 <test> |
| 474 <param name="input" value="test.bam" ftype="bam" /> | 634 <param name="input" value="test.bam" ftype="bam" /> |
| 475 <conditional name="mode"> | 635 <conditional name="mode"> |
| 476 <param name="outtype" value="selected_reads" /> | 636 <param name="outtype" value="selected_reads" /> |
| 490 <param name="addref_select" value="history" /> | 650 <param name="addref_select" value="history" /> |
| 491 <param name="ref" value="test.fa" /> | 651 <param name="ref" value="test.fa" /> |
| 492 </conditional> | 652 </conditional> |
| 493 <output name="outputsam" file="test.cram" ftype="cram" compare="sim_size" delta="250" /> | 653 <output name="outputsam" file="test.cram" ftype="cram" compare="sim_size" delta="250" /> |
| 494 </test> | 654 </test> |
| 495 <!-- bam to sam + header options (adapted from bam_to_sam tool)--> | |
| 496 <test> | |
| 497 <param ftype="bam" name="input" value="bam_to_sam_in1.bam" /> | |
| 498 <conditional name="mode"> | |
| 499 <conditional name="output_options"> | |
| 500 <conditional name="output_format"> | |
| 501 <param name="oformat" value="sam" /> | |
| 502 <param name="with_header" value="true" /> | |
| 503 </conditional> | |
| 504 </conditional> | |
| 505 </conditional> | |
| 506 <output file="bam_to_sam_out1.sam" ftype="sam" name="outputsam" /> | |
| 507 </test> | |
| 508 <test> | |
| 509 <param ftype="bam" name="input" value="bam_to_sam_in1.bam" /> | |
| 510 <conditional name="mode"> | |
| 511 <param name="outtype" value="header" /> | |
| 512 <conditional name="output_options"> | |
| 513 <conditional name="output_format"> | |
| 514 <param name="oformat" value="sam" /> | |
| 515 </conditional> | |
| 516 </conditional> | |
| 517 </conditional> | |
| 518 <output file="bam_to_sam_out2.sam" ftype="sam" name="outputsam" /> | |
| 519 </test> | |
| 520 <test> | |
| 521 <param ftype="bam" name="input" value="bam_to_sam_in1.bam" /> | |
| 522 <conditional name="mode"> | |
| 523 <conditional name="output_options"> | |
| 524 <conditional name="output_format"> | |
| 525 <param name="oformat" value="sam" /> | |
| 526 <param name="with_header" value="false" /> | |
| 527 </conditional> | |
| 528 </conditional> | |
| 529 </conditional> | |
| 530 <output file="bam_to_sam_out3.sam" ftype="sam" name="outputsam" /> | |
| 531 </test> | |
| 532 <!-- cram to bam + region (adapted from cram_to_bam tool)--> | |
| 533 <test> | |
| 534 <param name="input" value="test.cram" ftype="cram" /> | |
| 535 <conditional name="addref_cond"> | |
| 536 <param name="addref_select" value="history" /> | |
| 537 <param name="ref" value="test.fa" /> | |
| 538 </conditional> | |
| 539 <output name="outputsam" file="test.bam" ftype="bam" /> | |
| 540 </test> | |
| 541 <test> | 655 <test> |
| 542 <param name="input" value="test.cram" ftype="cram" /> | 656 <param name="input" value="test.cram" ftype="cram" /> |
| 543 <conditional name="mode"> | 657 <conditional name="mode"> |
| 544 <param name="outtype" value="selected_reads" /> | 658 <param name="outtype" value="selected_reads" /> |
| 545 <section name="filter_config"> | 659 <section name="filter_config"> |
| 580 <param name="addref_select" value="history" /> | 694 <param name="addref_select" value="history" /> |
| 581 <param name="ref" value="test.fa" /> | 695 <param name="ref" value="test.fa" /> |
| 582 </conditional> | 696 </conditional> |
| 583 <output name="outputsam" file="test.bam" ftype="bam" /> | 697 <output name="outputsam" file="test.bam" ftype="bam" /> |
| 584 </test> | 698 </test> |
| 585 <test> | 699 |
| 586 <param name="input" value="test2.cram" dbkey="equCab2" ftype="cram" /> | |
| 587 <conditional name="mode"> | |
| 588 <param name="outtype" value="selected_reads" /> | |
| 589 <section name="filter_config"> | |
| 590 <conditional name="cond_region"> | |
| 591 <param name="select_region" value="no"/> | |
| 592 </conditional> | |
| 593 </section> | |
| 594 <conditional name="output_options"> | |
| 595 <conditional name="output_format"> | |
| 596 <param name="oformat" value="bam" /> | |
| 597 </conditional> | |
| 598 </conditional> | |
| 599 </conditional> | |
| 600 <conditional name="addref_cond"> | |
| 601 <param name="addref_select" value="cached" /> | |
| 602 <param name="ref" value="equCab2chrM" /> | |
| 603 </conditional> | |
| 604 <output name="outputsam" file="sam_to_bam_out2.bam" ftype="bam" /> | |
| 605 </test> | |
| 606 <!-- sampling options--> | 700 <!-- sampling options--> |
| 607 <test> | 701 <test> |
| 608 <param name="input" value="test.sam" ftype="sam" /> | 702 <param name="input" value="test.sam" ftype="sam" /> |
| 609 <conditional name="mode"> | 703 <conditional name="mode"> |
| 610 <param name="outtype" value="selected_reads" /> | 704 <param name="outtype" value="selected_reads" /> |
| 614 <param name="target" value="2" /> | 708 <param name="target" value="2" /> |
| 615 </conditional> | 709 </conditional> |
| 616 </section> | 710 </section> |
| 617 <conditional name="output_options"> | 711 <conditional name="output_options"> |
| 618 <conditional name="output_format"> | 712 <conditional name="output_format"> |
| 619 <param name="oformat" value="sam" /> | 713 <param name="oformat" value="input" /> |
| 620 </conditional> | 714 </conditional> |
| 621 </conditional> | 715 </conditional> |
| 622 </conditional> | 716 </conditional> |
| 623 <output name="outputsam" file="test_ds.sam" ftype="sam" compare="diff" lines_diff="6" /> | 717 <output name="outputsam" file="test_ds.sam" ftype="sam" compare="diff" lines_diff="6" /> |
| 624 </test> | 718 </test> |
| 632 <param name="target" value="20" /> | 726 <param name="target" value="20" /> |
| 633 </conditional> | 727 </conditional> |
| 634 </section> | 728 </section> |
| 635 <conditional name="output_options"> | 729 <conditional name="output_options"> |
| 636 <conditional name="output_format"> | 730 <conditional name="output_format"> |
| 637 <param name="oformat" value="sam" /> | 731 <param name="oformat" value="input" /> |
| 638 </conditional> | 732 </conditional> |
| 639 </conditional> | 733 </conditional> |
| 640 </conditional> | 734 </conditional> |
| 641 <output name="outputsam" file="test.sam" ftype="sam" /> | 735 <output name="outputsam" file="test.sam" ftype="sam" /> |
| 736 </test> | |
| 737 <test> | |
| 738 <!-- subsampling SAM input without reads --> | |
| 739 <param name="input" value="no_reads.sam" ftype="sam" /> | |
| 740 <conditional name="mode"> | |
| 741 <param name="outtype" value="selected_reads" /> | |
| 742 <section name="subsample_config"> | |
| 743 <conditional name="subsampling_mode"> | |
| 744 <param name="select_subsample" value="target" /> | |
| 745 <param name="target" value="20" /> | |
| 746 </conditional> | |
| 747 </section> | |
| 748 <conditional name="output_options"> | |
| 749 <conditional name="output_format"> | |
| 750 <param name="oformat" value="input" /> | |
| 751 </conditional> | |
| 752 </conditional> | |
| 753 </conditional> | |
| 754 <output name="outputsam" file="no_reads.sam" ftype="sam" /> | |
| 755 </test> | |
| 756 <test> | |
| 757 <!-- subsampling BAM input without reads --> | |
| 758 <param name="input" value="no_reads.bam" ftype="bam" /> | |
| 759 <conditional name="mode"> | |
| 760 <param name="outtype" value="selected_reads" /> | |
| 761 <section name="subsample_config"> | |
| 762 <conditional name="subsampling_mode"> | |
| 763 <param name="select_subsample" value="target" /> | |
| 764 <param name="target" value="20" /> | |
| 765 </conditional> | |
| 766 </section> | |
| 767 <conditional name="output_options"> | |
| 768 <conditional name="output_format"> | |
| 769 <param name="oformat" value="input" /> | |
| 770 </conditional> | |
| 771 </conditional> | |
| 772 </conditional> | |
| 773 <output name="outputsam" file="no_reads.bam" ftype="bam" /> | |
| 642 </test> | 774 </test> |
| 643 <test> | 775 <test> |
| 644 <param name="input" value="test.sam" ftype="sam" /> | 776 <param name="input" value="test.sam" ftype="sam" /> |
| 645 <conditional name="mode"> | 777 <conditional name="mode"> |
| 646 <param name="outtype" value="selected_reads" /> | 778 <param name="outtype" value="selected_reads" /> |
| 651 <param name="target" value="2" /> | 783 <param name="target" value="2" /> |
| 652 </conditional> | 784 </conditional> |
| 653 </section> | 785 </section> |
| 654 <conditional name="output_options"> | 786 <conditional name="output_options"> |
| 655 <conditional name="output_format"> | 787 <conditional name="output_format"> |
| 656 <param name="oformat" value="sam" /> | 788 <param name="oformat" value="input" /> |
| 657 </conditional> | 789 </conditional> |
| 658 </conditional> | 790 </conditional> |
| 659 </conditional> | 791 </conditional> |
| 660 <output name="outputsam" file="test_ds.sam" ftype="sam" compare="diff" lines_diff="6" /> | 792 <output name="outputsam" file="test_ds.sam" ftype="sam" compare="diff" lines_diff="6" /> |
| 661 </test> | 793 </test> |
| 670 <param name="target" value="2" /> | 802 <param name="target" value="2" /> |
| 671 </conditional> | 803 </conditional> |
| 672 </section> | 804 </section> |
| 673 <conditional name="output_options"> | 805 <conditional name="output_options"> |
| 674 <conditional name="output_format"> | 806 <conditional name="output_format"> |
| 675 <param name="oformat" value="bam" /> | 807 <param name="oformat" value="input" /> |
| 676 </conditional> | 808 </conditional> |
| 677 </conditional> | 809 </conditional> |
| 678 </conditional> | 810 </conditional> |
| 679 <output name="outputsam" file="test_ds.bam" ftype="bam" /> | 811 <output name="outputsam" file="test_ds.bam" ftype="bam" /> |
| 680 </test> | 812 </test> |
| 689 <param name="target" value="20" /> | 821 <param name="target" value="20" /> |
| 690 </conditional> | 822 </conditional> |
| 691 </section> | 823 </section> |
| 692 <conditional name="output_options"> | 824 <conditional name="output_options"> |
| 693 <conditional name="output_format"> | 825 <conditional name="output_format"> |
| 694 <param name="oformat" value="bam" /> | 826 <param name="oformat" value="input" /> |
| 695 </conditional> | 827 </conditional> |
| 696 </conditional> | 828 </conditional> |
| 697 </conditional> | 829 </conditional> |
| 698 <output name="outputsam" file="test.bam" ftype="bam" /> | 830 <output name="outputsam" file="test.bam" ftype="bam" /> |
| 699 </test> | 831 </test> |
| 708 <param name="factor" value="5" /> | 840 <param name="factor" value="5" /> |
| 709 </conditional> | 841 </conditional> |
| 710 </section> | 842 </section> |
| 711 <conditional name="output_options"> | 843 <conditional name="output_options"> |
| 712 <conditional name="output_format"> | 844 <conditional name="output_format"> |
| 713 <param name="oformat" value="bam" /> | 845 <param name="oformat" value="input" /> |
| 714 </conditional> | 846 </conditional> |
| 715 </conditional> | 847 </conditional> |
| 716 </conditional> | 848 </conditional> |
| 717 <output name="outputsam" file="test_ds.bam" ftype="bam" /> | 849 <output name="outputsam" file="test_ds.bam" ftype="bam" /> |
| 718 </test> | 850 </test> |
| 728 </conditional> | 860 </conditional> |
| 729 </section> | 861 </section> |
| 730 <conditional name="output_options"> | 862 <conditional name="output_options"> |
| 731 <param name="reads_report_type" value="dropped" /> | 863 <param name="reads_report_type" value="dropped" /> |
| 732 <conditional name="output_format"> | 864 <conditional name="output_format"> |
| 733 <param name="oformat" value="bam" /> | 865 <param name="oformat" value="input" /> |
| 734 </conditional> | 866 </conditional> |
| 735 </conditional> | 867 </conditional> |
| 736 </conditional> | 868 </conditional> |
| 737 <output name="outputsam" file="test_ds.bam" ftype="bam" /> | 869 <output name="outputsam" file="test_ds.bam" ftype="bam" /> |
| 738 </test> | 870 </test> |
