comparison edger.xml @ 15:119f41ec0ada draft

planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/edger commit 76bd257ee51e9d7b912f570fb9ced1084ef44212
author iuc
date Wed, 15 Oct 2025 10:24:03 +0000
parents c5fa04118f83
children 09965c918573
comparison
equal deleted inserted replaced
14:c5fa04118f83 15:119f41ec0ada
2 <description> 2 <description>
3 Perform differential expression of count data 3 Perform differential expression of count data
4 </description> 4 </description>
5 <macros> 5 <macros>
6 <token name="@TOOL_VERSION@">3.36.0</token> 6 <token name="@TOOL_VERSION@">3.36.0</token>
7 <token name="@VERSION_SUFFIX@">5</token> 7 <token name="@VERSION_SUFFIX@">6</token>
8 </macros> 8 </macros>
9 <edam_topics> 9 <edam_topics>
10 <edam_topic>topic_3308</edam_topic> 10 <edam_topic>topic_3308</edam_topic>
11 </edam_topics> 11 </edam_topics>
12 <edam_operations> 12 <edam_operations>
210 </param> 210 </param>
211 <when value="manual"> 211 <when value="manual">
212 <repeat name="rep_contrast" title="Contrast" min="1" default="1"> 212 <repeat name="rep_contrast" title="Contrast" min="1" default="1">
213 <param name="contrast" type="text" label="Contrast of Interest" help="Names of two groups to compare separated by a hyphen e.g. Mut-WT. If the order is Mut-WT the fold changes in the results will be up/down in Mut relative to WT. If you have more than one contrast enter each separately using the Insert Contrast button below. For differences between contrasts use e.g. (MT.t1-MT.t0)-(WT.t1-WT.t0). For more info, see Chapter 8 in the limma User's guide: https://www.bioconductor.org/packages/release/bioc/vignettes/limma/inst/doc/usersguide.pdf or https://bioconductor.org/packages/release/bioc/vignettes/edgeR/inst/doc/edgeRUsersGuide.pdf page 36 for nested comparisons."> 213 <param name="contrast" type="text" label="Contrast of Interest" help="Names of two groups to compare separated by a hyphen e.g. Mut-WT. If the order is Mut-WT the fold changes in the results will be up/down in Mut relative to WT. If you have more than one contrast enter each separately using the Insert Contrast button below. For differences between contrasts use e.g. (MT.t1-MT.t0)-(WT.t1-WT.t0). For more info, see Chapter 8 in the limma User's guide: https://www.bioconductor.org/packages/release/bioc/vignettes/limma/inst/doc/usersguide.pdf or https://bioconductor.org/packages/release/bioc/vignettes/edgeR/inst/doc/edgeRUsersGuide.pdf page 36 for nested comparisons.">
214 <validator type="empty_field"/> 214 <validator type="empty_field"/>
215 <validator type="regex" message="Please only use letters, numbers, parentheses or underscores">^[\w\-()]+$</validator> 215 <validator type="regex" message="Please only use letters, numbers, parentheses, colon or underscores">^[\w\-():]+$</validator>
216 </param> 216 </param>
217 </repeat> 217 </repeat>
218 </when> 218 </when>
219 <when value="file"> 219 <when value="file">
220 <param name="cinfo" optional="true" type="data" format="tabular" label="Contrasts File" help="Setting this file will ignore any manually added contrasts above, make sure to remove any contrast fields above pressing the trash bin icon, or the tool will fail. First line of the file must be a header, below that each separate contrast should be on a line. Contrast formulas need to be based on ther factors data and potentially the formula provided. See EdgeR documentation on contrasts for more details."/> 220 <param name="cinfo" optional="true" type="data" format="tabular" label="Contrasts File" help="Setting this file will ignore any manually added contrasts above, make sure to remove any contrast fields above pressing the trash bin icon, or the tool will fail. First line of the file must be a header, below that each separate contrast should be on a line. Contrast formulas need to be based on ther factors data and potentially the formula provided. See EdgeR documentation on contrasts for more details."/>
293 </data> 293 </data>
294 </outputs> 294 </outputs>
295 <tests> 295 <tests>
296 <!-- Ensure report is output --> 296 <!-- Ensure report is output -->
297 <test expect_num_outputs="2"> 297 <test expect_num_outputs="2">
298 <param name="format" value="matrix"/> 298 <param name="input|format" value="matrix"/>
299 <param name="counts" value="matrix.txt"/> 299 <param name="input|counts" value="matrix.txt"/>
300 <repeat name="rep_factor"> 300 <param name="input|fact|ffile" value="no"/>
301 <repeat name="input|fact|rep_factor">
301 <param name="factorName" value="Genotype"/> 302 <param name="factorName" value="Genotype"/>
302 <param name="groupNames" value="Mut,Mut,Mut,WT,WT,WT"/> 303 <param name="groupNames" value="Mut,Mut,Mut,WT,WT,WT"/>
303 </repeat> 304 </repeat>
304 <param name="contrastOpt" value="manual"/> 305 <param name="contrasts|contrastOpt" value="manual"/>
305 <repeat name="rep_contrast"> 306 <repeat name="contrasts|rep_contrast">
306 <param name="contrast" value="Mut-WT"/> 307 <param name="contrast" value="Mut-WT"/>
307 </repeat> 308 </repeat>
308 <repeat name="rep_contrast"> 309 <repeat name="contrasts|rep_contrast">
309 <param name="contrast" value="WT-Mut"/> 310 <param name="contrast" value="WT-Mut"/>
310 </repeat> 311 </repeat>
311 <param name="normalisationOption" value="TMM"/> 312 <param name="adv|normalisationOption" value="TMM"/>
312 <output_collection name="outTables" count="2"> 313 <output_collection name="outTables" count="2">
313 <element name="edgeR_Mut-WT" ftype="tabular"> 314 <element name="edgeR_Mut-WT" ftype="tabular">
314 <assert_contents> 315 <assert_contents>
315 <has_text_matching expression="GeneID.*logFC.*logCPM.*F.*PValue.*FDR"/> 316 <has_text_matching expression="GeneID.*logFC.*logCPM.*F.*PValue.*FDR"/>
316 <has_text_matching expression="11304.*0.4582"/> 317 <has_text_matching expression="11304.*0.4582"/>
332 </assert_contents> 333 </assert_contents>
333 </output> 334 </output>
334 </test> 335 </test>
335 <!-- Complex contrasts constructions --> 336 <!-- Complex contrasts constructions -->
336 <test expect_num_outputs="2"> 337 <test expect_num_outputs="2">
337 <param name="format" value="matrix"/> 338 <param name="input|format" value="matrix"/>
338 <param name="counts" value="matrix-complex.txt"/> 339 <param name="input|counts" value="matrix-complex.txt"/>
339 <repeat name="rep_factor"> 340 <param name="input|fact|ffile" value="no"/>
341 <repeat name="input|fact|rep_factor">
340 <param name="factorName" value="Genotype"/> 342 <param name="factorName" value="Genotype"/>
341 <param name="groupNames" value="MutA,MutA,MutA,MutB,MutB,MutB,WTA,WTA,WTA,WTB,WTB,WTB"/> 343 <param name="groupNames" value="MutA,MutA,MutA,MutB,MutB,MutB,WTA,WTA,WTA,WTB,WTB,WTB"/>
342 </repeat> 344 </repeat>
343 <param name="contrastOpt" value="manual"/> 345 <param name="contrasts|contrastOpt" value="manual"/>
344 <repeat name="rep_contrast"> 346 <repeat name="contrasts|rep_contrast">
345 <param name="contrast" value="(MutA-MutB)-(WTA-WTB)"/> 347 <param name="contrast" value="(MutA-MutB)-(WTA-WTB)"/>
346 </repeat> 348 </repeat>
347 <param name="normalisationOption" value="TMM"/> 349 <param name="adv|normalisationOption" value="TMM"/>
348 <output_collection name="outTables" count="1"> 350 <output_collection name="outTables" count="1">
349 <element name="edgeR_(MutA-MutB)-(WTA-WTB)" ftype="tabular"> 351 <element name="edgeR_(MutA-MutB)-(WTA-WTB)" ftype="tabular">
350 <assert_contents> 352 <assert_contents>
351 <has_text_matching expression="GeneID.*logFC.*logCPM.*F.*PValue.*FDR"/> 353 <has_text_matching expression="GeneID.*logFC.*logCPM.*F.*PValue.*FDR"/>
352 <has_text_matching expression="11304.*15.53"/> 354 <has_text_matching expression="11304.*15.53"/>
362 </assert_contents> 364 </assert_contents>
363 </output> 365 </output>
364 </test> 366 </test>
365 <!-- Ensure annotation file input works --> 367 <!-- Ensure annotation file input works -->
366 <test expect_num_outputs="2"> 368 <test expect_num_outputs="2">
367 <param name="format" value="matrix"/> 369 <param name="input|format" value="matrix"/>
368 <param name="annoOpt" value="yes"/> 370 <param name="anno|annoOpt" value="yes"/>
369 <param name="geneanno" value="anno.txt"/> 371 <param name="anno|geneanno" value="anno.txt"/>
370 <param name="counts" value="matrix.txt"/> 372 <param name="input|counts" value="matrix.txt"/>
371 <repeat name="rep_factor"> 373 <param name="input|fact|ffile" value="no"/>
374 <repeat name="input|fact|rep_factor">
372 <param name="factorName" value="Genotype"/> 375 <param name="factorName" value="Genotype"/>
373 <param name="groupNames" value="Mut,Mut,Mut,WT,WT,WT"/> 376 <param name="groupNames" value="Mut,Mut,Mut,WT,WT,WT"/>
374 </repeat> 377 </repeat>
375 <param name="contrastOpt" value="manual"/> 378 <param name="contrasts|contrastOpt" value="manual"/>
376 <repeat name="rep_contrast"> 379 <repeat name="contrasts|rep_contrast">
377 <param name="contrast" value="Mut-WT"/> 380 <param name="contrast" value="Mut-WT"/>
378 </repeat> 381 </repeat>
379 <param name="normalisationOption" value="TMM"/> 382 <param name="adv|normalisationOption" value="TMM"/>
380 <output_collection name="outTables" count="1"> 383 <output_collection name="outTables" count="1">
381 <element name="edgeR_Mut-WT" ftype="tabular"> 384 <element name="edgeR_Mut-WT" ftype="tabular">
382 <assert_contents> 385 <assert_contents>
383 <has_text_matching expression="EntrezID.*Symbol.*logFC.*logCPM.*F.*PValue.*FDR"/> 386 <has_text_matching expression="EntrezID.*Symbol.*logFC.*logCPM.*F.*PValue.*FDR"/>
384 <has_text_matching expression="11304.*Abca4.*0.4582"/> 387 <has_text_matching expression="11304.*Abca4.*0.4582"/>
386 </element> 389 </element>
387 </output_collection> 390 </output_collection>
388 </test> 391 </test>
389 <!-- Ensure RScript and RData file can be output --> 392 <!-- Ensure RScript and RData file can be output -->
390 <test expect_num_outputs="3"> 393 <test expect_num_outputs="3">
391 <param name="format" value="matrix"/> 394 <param name="input|format" value="matrix"/>
392 <param name="rscript" value="True"/> 395 <param name="out|rscript" value="True"/>
393 <param name="rdaOption" value="true"/> 396 <param name="out|rdaOption" value="true"/>
394 <param name="counts" value="matrix.txt"/> 397 <param name="input|counts" value="matrix.txt"/>
395 <repeat name="rep_factor"> 398 <param name="input|fact|ffile" value="no"/>
399 <repeat name="input|fact|rep_factor">
396 <param name="factorName" value="Genotype"/> 400 <param name="factorName" value="Genotype"/>
397 <param name="groupNames" value="Mut,Mut,Mut,WT,WT,WT"/> 401 <param name="groupNames" value="Mut,Mut,Mut,WT,WT,WT"/>
398 </repeat> 402 </repeat>
399 <param name="contrastOpt" value="manual"/> 403 <param name="contrasts|contrastOpt" value="manual"/>
400 <repeat name="rep_contrast"> 404 <repeat name="contrasts|rep_contrast">
401 <param name="contrast" value="Mut-WT"/> 405 <param name="contrast" value="Mut-WT"/>
402 </repeat> 406 </repeat>
403 <param name="normalisationOption" value="TMM"/> 407 <param name="adv|normalisationOption" value="TMM"/>
404 <output name="outReport"> 408 <output name="outReport">
405 <assert_contents> 409 <assert_contents>
406 <has_text text="RData"/> 410 <has_text text="RData"/>
407 </assert_contents> 411 </assert_contents>
408 </output> 412 </output>
412 </assert_contents> 416 </assert_contents>
413 </output> 417 </output>
414 </test> 418 </test>
415 <!-- Ensure secondary factors work --> 419 <!-- Ensure secondary factors work -->
416 <test expect_num_outputs="2"> 420 <test expect_num_outputs="2">
417 <param name="format" value="matrix"/> 421 <param name="input|format" value="matrix"/>
418 <param name="counts" value="matrix.txt"/> 422 <param name="input|counts" value="matrix.txt"/>
419 <repeat name="rep_factor"> 423 <param name="input|fact|ffile" value="no"/>
424 <repeat name="input|fact|rep_factor">
420 <param name="factorName" value="Genotype"/> 425 <param name="factorName" value="Genotype"/>
421 <param name="groupNames" value="Mut,Mut,Mut,WT,WT,WT"/> 426 <param name="groupNames" value="Mut,Mut,Mut,WT,WT,WT"/>
422 </repeat> 427 </repeat>
423 <repeat name="rep_factor"> 428 <repeat name="input|fact|rep_factor">
424 <param name="factorName" value="Batch"/> 429 <param name="factorName" value="Batch"/>
425 <param name="groupNames" value="b1,b2,b3,b1,b2,b3"/> 430 <param name="groupNames" value="b1,b2,b3,b1,b2,b3"/>
426 </repeat> 431 </repeat>
427 <param name="contrastOpt" value="manual"/> 432 <param name="contrasts|contrastOpt" value="manual"/>
428 <repeat name="rep_contrast"> 433 <repeat name="contrasts|rep_contrast">
429 <param name="contrast" value="Mut-WT"/> 434 <param name="contrast" value="Mut-WT"/>
430 </repeat> 435 </repeat>
431 <param name="normalisationOption" value="TMM"/> 436 <param name="adv|normalisationOption" value="TMM"/>
432 <output_collection name="outTables" count="1"> 437 <output_collection name="outTables" count="1">
433 <element name="edgeR_Mut-WT" ftype="tabular"> 438 <element name="edgeR_Mut-WT" ftype="tabular">
434 <assert_contents> 439 <assert_contents>
435 <has_text_matching expression="GeneID.*logFC.*logCPM.*F.*PValue.*FDR"/> 440 <has_text_matching expression="GeneID.*logFC.*logCPM.*F.*PValue.*FDR"/>
436 <has_text_matching expression="11304.*0.4584"/> 441 <has_text_matching expression="11304.*0.4584"/>
438 </element> 443 </element>
439 </output_collection> 444 </output_collection>
440 </test> 445 </test>
441 <!-- Ensure factors file with unordered samples works --> 446 <!-- Ensure factors file with unordered samples works -->
442 <test expect_num_outputs="2"> 447 <test expect_num_outputs="2">
443 <param name="format" value="matrix"/> 448 <param name="input|format" value="matrix"/>
444 <param name="ffile" value="yes"/> 449 <param name="input|fact|ffile" value="yes"/>
445 <param name="finfo" value="factorinfo.txt"/> 450 <param name="input|fact|finfo" value="factorinfo.txt"/>
446 <param name="counts" value="matrix.txt"/> 451 <param name="input|counts" value="matrix.txt"/>
447 <param name="contrastOpt" value="manual"/> 452 <param name="contrasts|contrastOpt" value="manual"/>
448 <repeat name="rep_contrast"> 453 <repeat name="contrasts|rep_contrast">
449 <param name="contrast" value="Mut-WT"/> 454 <param name="contrast" value="Mut-WT"/>
450 </repeat> 455 </repeat>
451 <param name="normalisationOption" value="TMM"/> 456 <param name="adv|normalisationOption" value="TMM"/>
452 <output_collection name="outTables" count="1"> 457 <output_collection name="outTables" count="1">
453 <element name="edgeR_Mut-WT" ftype="tabular"> 458 <element name="edgeR_Mut-WT" ftype="tabular">
454 <assert_contents> 459 <assert_contents>
455 <has_text_matching expression="GeneID.*logFC.*logCPM.*F.*PValue.*FDR"/> 460 <has_text_matching expression="GeneID.*logFC.*logCPM.*F.*PValue.*FDR"/>
456 <has_text_matching expression="11304.*0.4584"/> 461 <has_text_matching expression="11304.*0.4584"/>
458 </element> 463 </element>
459 </output_collection> 464 </output_collection>
460 </test> 465 </test>
461 <!-- Ensure normalised counts file output works--> 466 <!-- Ensure normalised counts file output works-->
462 <test expect_num_outputs="2"> 467 <test expect_num_outputs="2">
463 <param name="format" value="matrix"/> 468 <param name="input|format" value="matrix"/>
464 <param name="normCounts" value="true"/> 469 <param name="out|normCounts" value="true"/>
465 <param name="counts" value="matrix.txt"/> 470 <param name="input|counts" value="matrix.txt"/>
466 <repeat name="rep_factor"> 471 <param name="input|fact|ffile" value="no"/>
472 <repeat name="input|fact|rep_factor">
467 <param name="factorName" value="Genotype"/> 473 <param name="factorName" value="Genotype"/>
468 <param name="groupNames" value="Mut,Mut,Mut,WT,WT,WT"/> 474 <param name="groupNames" value="Mut,Mut,Mut,WT,WT,WT"/>
469 </repeat> 475 </repeat>
470 <param name="contrastOpt" value="manual"/> 476 <param name="contrasts|contrastOpt" value="manual"/>
471 <repeat name="rep_contrast"> 477 <repeat name="contrasts|rep_contrast">
472 <param name="contrast" value="Mut-WT"/> 478 <param name="contrast" value="Mut-WT"/>
473 </repeat> 479 </repeat>
474 <param name="normalisationOption" value="TMM"/> 480 <param name="adv|normalisationOption" value="TMM"/>
475 <output_collection name="outTables" count="2"> 481 <output_collection name="outTables" count="2">
476 <element name="edgeR_Mut-WT" ftype="tabular"> 482 <element name="edgeR_Mut-WT" ftype="tabular">
477 <assert_contents> 483 <assert_contents>
478 <has_text_matching expression="GeneID.*logFC.*logCPM.*F.*PValue.*FDR"/> 484 <has_text_matching expression="GeneID.*logFC.*logCPM.*F.*PValue.*FDR"/>
479 <has_text_matching expression="11304.*0.4582"/> 485 <has_text_matching expression="11304.*0.4582"/>
487 </element> 493 </element>
488 </output_collection> 494 </output_collection>
489 </test> 495 </test>
490 <!-- Ensure likelihood ratio option works --> 496 <!-- Ensure likelihood ratio option works -->
491 <test expect_num_outputs="2"> 497 <test expect_num_outputs="2">
492 <param name="format" value="matrix"/> 498 <param name="input|format" value="matrix"/>
493 <param name="counts" value="matrix.txt"/> 499 <param name="input|counts" value="matrix.txt"/>
494 <repeat name="rep_factor"> 500 <param name="input|fact|ffile" value="no"/>
501 <repeat name="input|fact|rep_factor">
495 <param name="factorName" value="Genotype"/> 502 <param name="factorName" value="Genotype"/>
496 <param name="groupNames" value="Mut,Mut,Mut,WT,WT,WT"/> 503 <param name="groupNames" value="Mut,Mut,Mut,WT,WT,WT"/>
497 </repeat> 504 </repeat>
498 <param name="contrastOpt" value="manual"/> 505 <param name="contrasts|contrastOpt" value="manual"/>
499 <repeat name="rep_contrast"> 506 <repeat name="contrasts|rep_contrast">
500 <param name="contrast" value="Mut-WT"/> 507 <param name="contrast" value="Mut-WT"/>
501 </repeat> 508 </repeat>
502 <param name="normalisationOption" value="TMM"/> 509 <param name="adv|normalisationOption" value="TMM"/>
503 <param name="lrtOption" value="true"/> 510 <param name="adv|lrtOption" value="true"/>
504 <output name="outReport"> 511 <output name="outReport">
505 <assert_contents> 512 <assert_contents>
506 <has_text text="likelihood ratio"/> 513 <has_text text="likelihood ratio"/>
507 <not_has_text text="quasi-likelihood"/> 514 <not_has_text text="quasi-likelihood"/>
508 </assert_contents> 515 </assert_contents>
509 </output> 516 </output>
510 </test> 517 </test>
511 <!-- Ensure multiple counts files input works --> 518 <!-- Ensure multiple counts files input works -->
512 <test expect_num_outputs="2"> 519 <test expect_num_outputs="2">
513 <param name="format" value="files"/> 520 <param name="input|format" value="files"/>
514 <repeat name="rep_factor"> 521 <repeat name="input|rep_factor">
515 <param name="factorName" value="Genotype"/> 522 <param name="factorName" value="Genotype"/>
516 <repeat name="rep_group"> 523 <repeat name="rep_group">
517 <param name="groupName" value="WT"/> 524 <param name="groupName" value="WT"/>
518 <param name="countsFile" value="WT1.counts,WT2.counts,WT3.counts"/> 525 <param name="countsFile" value="WT1.counts,WT2.counts,WT3.counts"/>
519 </repeat> 526 </repeat>
520 <repeat name="rep_group"> 527 <repeat name="rep_group">
521 <param name="groupName" value="Mut"/> 528 <param name="groupName" value="Mut"/>
522 <param name="countsFile" value="Mut1.counts,Mut2.counts,Mut3.counts"/> 529 <param name="countsFile" value="Mut1.counts,Mut2.counts,Mut3.counts"/>
523 </repeat> 530 </repeat>
524 </repeat> 531 </repeat>
525 <repeat name="rep_factor"> 532 <repeat name="input|rep_factor">
526 <param name="factorName" value="Batch"/> 533 <param name="factorName" value="Batch"/>
527 <repeat name="rep_group"> 534 <repeat name="rep_group">
528 <param name="groupName" value="b1"/> 535 <param name="groupName" value="b1"/>
529 <param name="countsFile" value="WT1.counts,Mut1.counts"/> 536 <param name="countsFile" value="WT1.counts,Mut1.counts"/>
530 </repeat> 537 </repeat>
535 <repeat name="rep_group"> 542 <repeat name="rep_group">
536 <param name="groupName" value="b3"/> 543 <param name="groupName" value="b3"/>
537 <param name="countsFile" value="WT3.counts,Mut3.counts"/> 544 <param name="countsFile" value="WT3.counts,Mut3.counts"/>
538 </repeat> 545 </repeat>
539 </repeat> 546 </repeat>
540 <param name="annoOpt" value="yes"/> 547 <param name="anno|annoOpt" value="yes"/>
541 <param name="geneanno" value="anno.txt"/> 548 <param name="anno|geneanno" value="anno.txt"/>
542 <param name="contrastOpt" value="manual"/> 549 <param name="contrasts|contrastOpt" value="manual"/>
543 <repeat name="rep_contrast"> 550 <repeat name="contrasts|rep_contrast">
544 <param name="contrast" value="Mut-WT"/> 551 <param name="contrast" value="Mut-WT"/>
545 </repeat> 552 </repeat>
546 <repeat name="rep_contrast"> 553 <repeat name="contrasts|rep_contrast">
547 <param name="contrast" value="WT-Mut"/> 554 <param name="contrast" value="WT-Mut"/>
548 </repeat> 555 </repeat>
549 <param name="normCounts" value="true"/> 556 <param name="out|normCounts" value="true"/>
550 <output_collection name="outTables" count="3"> 557 <output_collection name="outTables" count="3">
551 <element name="edgeR_Mut-WT" ftype="tabular"> 558 <element name="edgeR_Mut-WT" ftype="tabular">
552 <assert_contents> 559 <assert_contents>
553 <has_text_matching expression="EntrezID.*Symbol.*logFC.*logCPM.*F.*PValue.*FDR"/> 560 <has_text_matching expression="EntrezID.*Symbol.*logFC.*logCPM.*F.*PValue.*FDR"/>
554 <has_text_matching expression="11304.*Abca4.*0.4584"/> 561 <has_text_matching expression="11304.*Abca4.*0.4584"/>
568 </element> 575 </element>
569 </output_collection> 576 </output_collection>
570 </test> 577 </test>
571 <!-- Ensure filtering on CPM in Mnimum Samples works --> 578 <!-- Ensure filtering on CPM in Mnimum Samples works -->
572 <test expect_num_outputs="2"> 579 <test expect_num_outputs="2">
573 <param name="format" value="matrix"/> 580 <param name="input|format" value="matrix"/>
574 <param name="counts" value="matrix.txt"/> 581 <param name="input|counts" value="matrix.txt"/>
575 <repeat name="rep_factor"> 582 <param name="input|fact|ffile" value="no"/>
583 <repeat name="input|fact|rep_factor">
576 <param name="factorName" value="Genotype"/> 584 <param name="factorName" value="Genotype"/>
577 <param name="groupNames" value="Mut,Mut,Mut,WT,WT,WT"/> 585 <param name="groupNames" value="Mut,Mut,Mut,WT,WT,WT"/>
578 </repeat> 586 </repeat>
579 <param name="contrastOpt" value="manual"/> 587 <param name="contrasts|contrastOpt" value="manual"/>
580 <repeat name="rep_contrast"> 588 <repeat name="contrasts|rep_contrast">
581 <param name="contrast" value="Mut-WT"/> 589 <param name="contrast" value="Mut-WT"/>
582 </repeat> 590 </repeat>
583 <param name="normalisationOption" value="TMM"/> 591 <param name="adv|normalisationOption" value="TMM"/>
584 <param name="filt_select" value="yes"/> 592 <param name="f|filt|filt_select" value="yes"/>
585 <param name="format_select" value="cpm"/> 593 <param name="f|filt|cformat|format_select" value="cpm"/>
586 <!-- real cpmReq values would be a lot lower 594 <!-- real cpmReq values would be a lot lower
587 this is just for this tiny test dataset --> 595 this is just for this tiny test dataset -->
588 <param name="cpmReq" value="1000"/> 596 <param name="f|filt|cformat|cpmReq" value="1000"/>
589 <param name="cpmSampleReq" value="3"/> 597 <param name="f|filt|cformat|cpmSampleReq" value="3"/>
590 <output name="outReport"> 598 <output name="outReport">
591 <assert_contents> 599 <assert_contents>
592 <has_text text="CPM in at least"/> 600 <has_text text="CPM in at least"/>
593 <not_has_text text="after summing counts for all samples"/> 601 <not_has_text text="after summing counts for all samples"/>
594 <not_has_text text="counts in at least"/> 602 <not_has_text text="counts in at least"/>
604 </element> 612 </element>
605 </output_collection> 613 </output_collection>
606 </test> 614 </test>
607 <!-- Ensure filtering on Count in Minmum Samples works --> 615 <!-- Ensure filtering on Count in Minmum Samples works -->
608 <test expect_num_outputs="2"> 616 <test expect_num_outputs="2">
609 <param name="format" value="matrix"/> 617 <param name="input|format" value="matrix"/>
610 <param name="counts" value="matrix.txt"/> 618 <param name="input|counts" value="matrix.txt"/>
611 <repeat name="rep_factor"> 619 <param name="input|fact|ffile" value="no"/>
620 <repeat name="input|fact|rep_factor">
612 <param name="factorName" value="Genotype"/> 621 <param name="factorName" value="Genotype"/>
613 <param name="groupNames" value="Mut,Mut,Mut,WT,WT,WT"/> 622 <param name="groupNames" value="Mut,Mut,Mut,WT,WT,WT"/>
614 </repeat> 623 </repeat>
615 <param name="contrastOpt" value="manual"/> 624 <param name="contrasts|contrastOpt" value="manual"/>
616 <repeat name="rep_contrast"> 625 <repeat name="contrasts|rep_contrast">
617 <param name="contrast" value="Mut-WT"/> 626 <param name="contrast" value="Mut-WT"/>
618 </repeat> 627 </repeat>
619 <param name="normalisationOption" value="TMM"/> 628 <param name="adv|normalisationOption" value="TMM"/>
620 <param name="filt_select" value="yes"/> 629 <param name="f|filt|filt_select" value="yes"/>
621 <param name="format_select" value="counts"/> 630 <param name="f|filt|cformat|format_select" value="counts"/>
622 <param name="cntReq" value="10"/> 631 <param name="f|filt|cformat|cntReq" value="10"/>
623 <param name="count_select" value="sample"/> 632 <param name="f|filt|cformat|samples|count_select" value="sample"/>
624 <param name="cntSampleReq" value="3"/> 633 <param name="f|filt|cformat|samples|cntSampleReq" value="3"/>
625 <output name="outReport"> 634 <output name="outReport">
626 <assert_contents> 635 <assert_contents>
627 <has_text text="counts in at least"/> 636 <has_text text="counts in at least"/>
628 <not_has_text text="after summing counts for all samples"/> 637 <not_has_text text="after summing counts for all samples"/>
629 <not_has_text text="CPM in at least"/> 638 <not_has_text text="CPM in at least"/>
639 </element> 648 </element>
640 </output_collection> 649 </output_collection>
641 </test> 650 </test>
642 <!-- Ensure filtering on Total Count works --> 651 <!-- Ensure filtering on Total Count works -->
643 <test expect_num_outputs="2"> 652 <test expect_num_outputs="2">
644 <param name="format" value="matrix"/> 653 <param name="input|format" value="matrix"/>
645 <param name="counts" value="matrix.txt"/> 654 <param name="input|counts" value="matrix.txt"/>
646 <repeat name="rep_factor"> 655 <param name="input|fact|ffile" value="no"/>
656 <repeat name="input|fact|rep_factor">
647 <param name="factorName" value="Genotype"/> 657 <param name="factorName" value="Genotype"/>
648 <param name="groupNames" value="Mut,Mut,Mut,WT,WT,WT"/> 658 <param name="groupNames" value="Mut,Mut,Mut,WT,WT,WT"/>
649 </repeat> 659 </repeat>
650 <param name="contrastOpt" value="manual"/> 660 <param name="contrasts|contrastOpt" value="manual"/>
651 <repeat name="rep_contrast"> 661 <repeat name="contrasts|rep_contrast">
652 <param name="contrast" value="Mut-WT"/> 662 <param name="contrast" value="Mut-WT"/>
653 </repeat> 663 </repeat>
654 <param name="normalisationOption" value="TMM"/> 664 <param name="adv|normalisationOption" value="TMM"/>
655 <param name="filt_select" value="yes"/> 665 <param name="f|filt|filt_select" value="yes"/>
656 <param name="format_select" value="counts"/> 666 <param name="f|filt|cformat|format_select" value="counts"/>
657 <!-- real cntReq values would be a lot lower 667 <!-- real cntReq values would be a lot lower
658 this is just for this tiny test dataset --> 668 this is just for this tiny test dataset -->
659 <param name="cntReq" value="1000"/> 669 <param name="f|filt|cformat|cntReq" value="1000"/>
660 <param name="count_select" value="total"/> 670 <param name="f|filt|cformat|samples|count_select" value="total"/>
661 <output name="outReport"> 671 <output name="outReport">
662 <assert_contents> 672 <assert_contents>
663 <has_text text="after summing counts for all samples"/> 673 <has_text text="after summing counts for all samples"/>
664 <not_has_text text="counts in at least"/> 674 <not_has_text text="counts in at least"/>
665 <not_has_text text="CPM in at least"/> 675 <not_has_text text="CPM in at least"/>
675 </element> 685 </element>
676 </output_collection> 686 </output_collection>
677 </test> 687 </test>
678 <!-- Ensure formula and contrast file work --> 688 <!-- Ensure formula and contrast file work -->
679 <test expect_num_outputs="2"> 689 <test expect_num_outputs="2">
680 <param name="format" value="matrix"/> 690 <param name="input|format" value="matrix"/>
681 <param name="counts" value="matrix.txt"/> 691 <param name="input|counts" value="matrix.txt"/>
682 <repeat name="rep_factor"> 692 <param name="input|fact|ffile" value="no"/>
693 <repeat name="input|fact|rep_factor">
683 <param name="factorName" value="Genotype"/> 694 <param name="factorName" value="Genotype"/>
684 <param name="groupNames" value="Mut,Mut,Mut,WT,WT,WT"/> 695 <param name="groupNames" value="Mut,Mut,Mut,WT,WT,WT"/>
685 </repeat> 696 </repeat>
686 <repeat name="rep_factor"> 697 <repeat name="input|fact|rep_factor">
687 <param name="factorName" value="Batch"/> 698 <param name="factorName" value="Batch"/>
688 <param name="groupNames" value="b1,b2,b3,b1,b2,b3"/> 699 <param name="groupNames" value="b1,b2,b3,b1,b2,b3"/>
689 </repeat> 700 </repeat>
690 <param name="contrastOpt" value="file"/> 701 <param name="contrasts|contrastOpt" value="file"/>
691 <param name="cinfo" value="contrasts_file.txt"/> 702 <param name="contrasts|cinfo" value="contrasts_file.txt"/>
692 <param name="formula" value="~ 0 + Genotype + Batch"/> 703 <param name="formula" value="~ 0 + Genotype + Batch"/>
693 <param name="normalisationOption" value="TMM"/> 704 <param name="adv|normalisationOption" value="TMM"/>
694 <output_collection name="outTables" count="3"> 705 <output_collection name="outTables" count="3">
695 <element name="edgeR_Mut-WT" ftype="tabular"> 706 <element name="edgeR_Mut-WT" ftype="tabular">
696 <assert_contents> 707 <assert_contents>
697 <has_text_matching expression="GeneID.*logFC.*logCPM.*F.*PValue.*FDR"/> 708 <has_text_matching expression="GeneID.*logFC.*logCPM.*F.*PValue.*FDR"/>
698 <has_text_matching expression="11304.*0.4584"/> 709 <has_text_matching expression="11304.*0.4584"/>
707 <assert_contents> 718 <assert_contents>
708 <has_text_matching expression="GeneID.*logFC.*logCPM.*F.*PValue.*FDR"/> 719 <has_text_matching expression="GeneID.*logFC.*logCPM.*F.*PValue.*FDR"/>
709 </assert_contents> 720 </assert_contents>
710 </element> 721 </element>
711 </output_collection> 722 </output_collection>
723 </test>
724 <!-- Test interaction contrasts with extended dataset (tests make.names fix for interaction terms) -->
725 <test expect_num_outputs="2">
726 <param name="input|format" value="matrix"/>
727 <param name="input|counts" value="matrix-extended.txt"/>
728 <param name="input|fact|ffile" value="yes"/>
729 <param name="input|fact|finfo" value="factorinfo-extended.txt"/>
730 <param name="formula" value="~ 0 + Genotype:Batch"/>
731 <param name="contrasts|contrastOpt" value="manual"/>
732 <repeat name="contrasts|rep_contrast">
733 <param name="contrast" value="Mut:b1-WT:b1"/>
734 </repeat>
735 <repeat name="contrasts|rep_contrast">
736 <param name="contrast" value="Mut:b2-Mut:b3"/>
737 </repeat>
738 <param name="adv|normalisationOption" value="TMM"/>
739 <output_collection name="outTables" count="2">
740 <element name="edgeR_Mut.b1-WT.b1" ftype="tabular">
741 <assert_contents>
742 <has_text_matching expression="GeneID.*logFC.*logCPM.*F.*PValue.*FDR"/>
743 <has_text_matching expression="11304"/>
744 </assert_contents>
745 </element>
746 <element name="edgeR_Mut.b2-Mut.b3" ftype="tabular">
747 <assert_contents>
748 <has_text_matching expression="GeneID.*logFC.*logCPM.*F.*PValue.*FDR"/>
749 <has_text_matching expression="11304"/>
750 </assert_contents>
751 </element>
752 </output_collection>
753 <output name="outReport">
754 <assert_contents>
755 <has_text text="edgeR Analysis Output"/>
756 <has_text text="quasi-likelihood"/>
757 </assert_contents>
758 </output>
759 </test>
760 <!-- Test full factorial interaction model (tests make.names fix with different interaction formula) -->
761 <test expect_num_outputs="2">
762 <param name="input|format" value="matrix"/>
763 <param name="input|counts" value="matrix-extended.txt"/>
764 <param name="input|fact|ffile" value="yes"/>
765 <param name="input|fact|finfo" value="factorinfo-extended.txt"/>
766 <param name="formula" value="~ Genotype * Batch"/>
767 <param name="contrasts|contrastOpt" value="manual"/>
768 <repeat name="contrasts|rep_contrast">
769 <param name="contrast" value="WT:b2"/>
770 </repeat>
771 <repeat name="contrasts|rep_contrast">
772 <param name="contrast" value="WT:b3-WT:b2"/>
773 </repeat>
774 <param name="adv|normalisationOption" value="TMM"/>
775 <output_collection name="outTables" count="2">
776 <element name="edgeR_WT.b2" ftype="tabular">
777 <assert_contents>
778 <has_text_matching expression="GeneID.*logFC.*logCPM.*F.*PValue.*FDR"/>
779 <has_text_matching expression="11304"/>
780 </assert_contents>
781 </element>
782 <element name="edgeR_WT.b3-WT.b2" ftype="tabular">
783 <assert_contents>
784 <has_text_matching expression="GeneID.*logFC.*logCPM.*F.*PValue.*FDR"/>
785 <has_text_matching expression="11304"/>
786 </assert_contents>
787 </element>
788 </output_collection>
789 <output name="outReport">
790 <assert_contents>
791 <has_text text="edgeR Analysis Output"/>
792 <has_text text="quasi-likelihood"/>
793 </assert_contents>
794 </output>
712 </test> 795 </test>
713 </tests> 796 </tests>
714 <help><![CDATA[ 797 <help><![CDATA[
715 .. class:: infomark 798 .. class:: infomark
716 799
808 Multiple contrasts must be entered separately using the Insert Contrast button, spaces must not be used. 891 Multiple contrasts must be entered separately using the Insert Contrast button, spaces must not be used.
809 892
810 Alternatively, you can specify a file with contrasts. The file must contain a header (it's value is irrelevant) 893 Alternatively, you can specify a file with contrasts. The file must contain a header (it's value is irrelevant)
811 and one contrast per line on the first column (other columns are ignored). If using this option, make sure to 894 and one contrast per line on the first column (other columns are ignored). If using this option, make sure to
812 remove any contrast section from the manual part, or the tool will fail. 895 remove any contrast section from the manual part, or the tool will fail.
896
897 **Working with Interactions:**
898 When you have multiple factors, you may want to test for interaction effects between them.
899 For example, with factors Genotype (Mut, WT) and Batch (b1, b2, b3), you might want to test
900 whether the effect of genotype differs between batches.
901
902 *Interaction Formula:* To include interaction terms, use the Formula field with one of these patterns:
903
904 - ``~ Genotype * Batch`` - Full factorial model (main effects + interactions)
905 - ``~ Genotype + Batch + Genotype:Batch`` - Equivalent to above
906 - ``~ 0 + Genotype:Batch`` - Cell-means model (each group combination separately)
907
908 The cell-means model (``~ 0 + Genotype:Batch``) is often preferred for testing specific
909 group comparisons as it creates individual parameters for each combination (e.g., Mut.b1, WT.b1, etc.).
910
911 *Interaction Contrasts:* When using interactions, contrast names will contain colons that get
912 converted to dots automatically. For example:
913
914 **Cell-means model contrasts** (with ``~ 0 + Genotype:Batch``):
915 - Input contrast: ``Mut:b1-WT:b1`` (compare Mut vs WT within batch b1)
916 - Input contrast: ``Mut:b2-Mut:b3`` (compare batch b2 vs b3 within Mut genotype)
917 - Output file names: ``edgeR_Mut.b1-WT.b1.tsv``, ``edgeR_Mut.b2-Mut.b3.tsv``
918
919 **Full factorial model contrasts** (with ``~ Genotype * Batch``):
920 - Input contrast: ``WT:b2`` (interaction effect: WT×b2 vs baseline)
921 - Input contrast: ``WT:b3-WT:b2`` (compare interaction effects: WT×b3 vs WT×b2)
922 - Output file names: ``edgeR_WT.b2.tsv``, ``edgeR_WT.b3-WT.b2.tsv``
923
924 *Using Contrasts Files with Interactions:* When using a contrasts file instead of manual entry,
925 the same interaction contrast syntax applies. Create a tab-separated file with a header and
926 one contrast per line:
927
928 Example contrasts file for cell-means model::
929
930 Contrast
931 Mut:b1-WT:b1
932 Mut:b2-Mut:b3
933 WT:b1-WT:b2
934
935 Example contrasts file for full factorial model::
936
937 Contrast
938 WT:b2
939 WT:b3-WT:b2
940 WT
941
942 The colons in contrast names will be automatically converted to dots in output file names,
943 regardless of whether contrasts are entered manually or via file.
944
945 Note: Ensure you have sufficient replicates for interaction models. With n factors each having
946 k levels, you need more than n×k samples to estimate interactions properly.
813 947
814 **Filter Low Counts:** 948 **Filter Low Counts:**
815 Genes with very low counts across all libraries provide little evidence for differential expression. 949 Genes with very low counts across all libraries provide little evidence for differential expression.
816 In the biological point of view, a gene must be expressed at some minimal level before 950 In the biological point of view, a gene must be expressed at some minimal level before
817 it is likely to be translated into a protein or to be biologically important. In addition, the 951 it is likely to be translated into a protein or to be biologically important. In addition, the