Commit cde650d3 authored by Mei's avatar Mei
Browse files

address biopet-609, fix broken links, reorganize layout.

parent dc6dc49c
...@@ -2,92 +2,88 @@ ...@@ -2,92 +2,88 @@
## Introduction ## Introduction
This pipeline is build for variant calling on NGS data (preferably Illumina data). This pipeline is built for variant calling on NGS data (preferably Illumina data). Part of this pipeline resembles the <a href="https://www.broadinstitute.org/gatk/guide/best-practices" target="_blank">best practices</a>) of GATK in terms of their approach to variant calling.
It is based on the <a href="https://www.broadinstitute.org/gatk/guide/best-practices" target="_blank">best practices</a>) of GATK in terms of their approach to variant calling.
The pipeline accepts ```.fastq & .bam``` files as input. The pipeline accepts ```.fastq & .bam``` files as input.
---- ----
## Tools for this pipeline ## Overview of tools and sub-pipelines for this pipeline
* [Flexiprep for QC](flexiprep.md)
* [Metagenomics analysis](gears.md)
* [Mapping](mapping.md)
* [VEP annotation](toucan.md)
* [Structual variant analysis](yamsvp.md)
* [CNV analysis](kopisu.md)
* <a href="http://broadinstitute.github.io/picard/" target="_blank">Picard tool suite</a> * <a href="http://broadinstitute.github.io/picard/" target="_blank">Picard tool suite</a>
* [Flexiprep](flexiprep.md)
* <a href="https://www.broadinstitute.org/gatk/" target="_blank">GATK tools</a>: * <a href="https://www.broadinstitute.org/gatk/" target="_blank">GATK tools</a>:
* GATK * Freebayes
* Freebayes * Varscan
* Bcftools * Bcftools
* Samtools * Samtools
---- ----
## Example ## Basic usage
Note that one should first create the appropriate [configs](../general/config.md). Note that one should first create the appropriate sample and pipeline setting [configs](../general/config.md).
### Sample input extensions Shiva pipeline can start from FASTQ or BAM files. This pipeline will include pre-process steps for the BAM files.
Please refer [to our mapping pipeline](mapping.md) for information about how the input samples should be handled. When using BAM files as input, Note that one should alter the sample config field from `R1` into `bam`.
Shiva is a special pipeline in the sense that it can also start directly from `bam` files. Note that one should alter the sample config field from `R1` into `bam`.
### Full pipeline
The full pipeline can start from fastq or from bam file. This pipeline will include pre-process steps for the bam files.
To view the help menu, execute: To view the help menu, execute:
~~~ ~~~
biopet pipeline shiva -h biopet pipeline shiva -h
Arguments for Shiva: Arguments for Shiva:
-sample,--onlysample <onlysample> Only Sample -s,--sample <sample> Only Process This Sample
-config,--config_file <config_file> JSON config file(s) -config,--config_file <config_file> JSON / YAML config file(s)
-DSC,--disablescatterdefault Disable all scatters -cv,--config_value <config_value> Config values, value should be formatted like 'key=value' or
'namespace:namespace:key=value'
-DSC,--disablescatter Disable all scatters
~~~ ~~~
To run the pipeline: To run the pipeline:
~~~ ~~~
biopet pipeline shiva -config MySamples.json -config MySettings.json -run biopet pipeline shiva -config MySamples.yml -config MySettings.yml -run
~~~ ~~~
A dry run can be performed by simply removing the `-run` flag from the command line call. A dry run can be performed by simply removing the `-run` flag from the command line call.
[Gears](gears) is run automatically for the data analysed with `Shiva`. There are two levels on which this can be done and this should be specified in the [config](../general/config) file: [Gears](gears.md) is run automatically for the data analysed with `Shiva`. There are two levels on which this can be done and this should be specified in the [config](../general/config) file:
*`mapping_to_gears: unmapped` : Unmapped reads after alignment. (default) *`mapping_to_gears: unmapped` : Unmapped reads after alignment. (default)
*`mapping_to_gears: all` : Trimmed and clipped reads from [Flexiprep](flexiprep). *`mapping_to_gears: all` : Trimmed and clipped reads from [Flexiprep](flexiprep).
*`mapping_to_gears: none` : Disable this functionality. *`mapping_to_gears: none` : Disable this functionality.
### Only variant calling An example of MySettings.yml file is provided here and more detailed config options are explained in [config options](#config-options).
``` yaml
It is possible to run Shiva while only performing its variant calling steps. samples:
This has been separated in its own pipeline named `shivavariantcalling`. SampleID:
As this calling pipeline starts from BAM files, it will naturally not perform any pre-processing steps. libraries:
lib_id_1:
To view the help menu, execute: bam: YourBam.bam
~~~ lib_id_2:
java -jar </path/to/biopet.jar> pipeline shivavariantcalling -h R1: file_R1.fq.gz
R2: file_R2.fq.gz
Arguments for ShivaVariantcalling: species: H.sapiens
-BAM,--inputbams <inputbams> Bam files (should be deduped bams) reference_name: GRCh38_no_alt_analysis_set
-sample,--sampleid <sampleid> Sample ID (only effects summary and not required) dbsnp_vcf: <dbsnp.vcf.gz>
-library,--libid <libid> Library ID (only effects summary and not required) vcffilter:
-config,--config_file <config_file> JSON config file(s) min_alternate_depth: 1
-DSC,--disablescatter Disable all scatters output_dir: <output directory>
variantcallers:
~~~ - haplotypecaller
- unifiedgenotyper
To run the pipeline: - haplotypecaller_gvcf
~~~ unifiedgenotyper:
biopet pipeline shivavariantcalling -config MySettings.json -run merge_vcf_results: false # This will do the variantcalling but will not merged into the final vcf file
~~~ ```
A dry run can be performed by simply removing the `-run` flag from the command line call.
---- ----
## Variant caller ## Supported variant callers
At this moment the following variant callers can be used At this moment the following variant callers can be used
* <a href="https://www.broadinstitute.org/gatk/gatkdocs/org_broadinstitute_gatk_tools_walkers_haplotypecaller_HaplotypeCaller.php">haplotypecaller</a> * <a href="https://www.broadinstitute.org/gatk/gatkdocs/org_broadinstitute_gatk_tools_walkers_haplotypecaller_HaplotypeCaller.php">haplotypecaller</a>
...@@ -104,21 +100,16 @@ At this moment the following variant callers can be used ...@@ -104,21 +100,16 @@ At this moment the following variant callers can be used
* <a href="https://samtools.github.io/bcftools/bcftools.html">bcftools_singlesample</a> * <a href="https://samtools.github.io/bcftools/bcftools.html">bcftools_singlesample</a>
* <a href="https://github.com/ekg/freebayes">freebayes</a> * <a href="https://github.com/ekg/freebayes">freebayes</a>
* <a href="http://varscan.sourceforge.net/">varscan</a> * <a href="http://varscan.sourceforge.net/">varscan</a>
* [raw](../tools/MpileupToVcf) * [Naive variant caller](../tools/MpileupToVcf)
## Config options ## Config options
To view all possible config options please navigate to our Gitlab wiki page
<a href="https://git.lumc.nl/biopet/biopet/wikis/GATK-Variantcalling-Pipeline" target="_blank">Config</a>
### Required settings ### Required settings
| Confignamespace | Name | Type | Default | Function | | Confignamespace | Name | Type | Default | Function |
| ----------- | ---- | ---- | ------- | -------- | | ----------- | ---- | ---- | ------- | -------- |
| - | output_dir | String | | Path to output directory | | - | output_dir | String | | Path to output directory |
| Shiva | variantcallers | List[String] | | Which variant callers to use | | Shiva | variantcallers | List[String] | | Which variant callers to use |
### Config options ### Config options
| ConfignNamespace | Name | Type | Default | Function | | ConfignNamespace | Name | Type | Default | Function |
...@@ -126,8 +117,9 @@ To view all possible config options please navigate to our Gitlab wiki page ...@@ -126,8 +117,9 @@ To view all possible config options please navigate to our Gitlab wiki page
| shiva | species | String | unknown_species | Name of species, like H.sapiens | | shiva | species | String | unknown_species | Name of species, like H.sapiens |
| shiva | reference_name | String | unknown_reference_name | Name of reference, like hg19 | | shiva | reference_name | String | unknown_reference_name | Name of reference, like hg19 |
| shiva | reference_fasta | String | | reference to align to | | shiva | reference_fasta | String | | reference to align to |
| shiva | dbsnp | String | | vcf file of dbsnp records | | shiva | dbsnp_vcf | String | | vcf file of dbsnp records |
| shiva | variantcallers | List[String] | | variantcaller to use, see list | | shiva | variantcallers | List[String] | | variantcaller to use, see list |
| shiva | input_alleles | String | | vcf file contains sites of interest for genotyping (including HOM REF calls). Only used when haplotypecaller_allele or unifiedgenotyper_allele is used. |
| shiva | use_indel_realigner | Boolean | true | Realign indels | | shiva | use_indel_realigner | Boolean | true | Realign indels |
| shiva | use_base_recalibration | Boolean | true | Base recalibrate | | shiva | use_base_recalibration | Boolean | true | Base recalibrate |
| shiva | use_analyze_covariates | Boolean | false | Analyze covariates during base recalibration step | | shiva | use_analyze_covariates | Boolean | false | Analyze covariates during base recalibration step |
...@@ -143,23 +135,16 @@ To view all possible config options please navigate to our Gitlab wiki page ...@@ -143,23 +135,16 @@ To view all possible config options please navigate to our Gitlab wiki page
Since Shiva uses the [Mapping](mapping.md) pipeline internally, mapping config values can be specified as well. Since Shiva uses the [Mapping](mapping.md) pipeline internally, mapping config values can be specified as well.
For all the options, please see the corresponding documentation for the mapping pipeline. For all the options, please see the corresponding documentation for the mapping pipeline.
### Exome variant calling ----
If one calls variants with Shiva on exome samples and a ```amplicon_bed``` file is available, the user is able to add this file to the config file. ## Advanced usage
When the file is given, the coverage over the positions in the bed file will be calculated plus the number of variants on each position. If there is an interest
in a specific region of the genome/exome one is capable to give multiple ```regionOfInterest.bed``` files with the option ```regions_of_interest``` (in list/array format).
A short recap: the option ```amplicon_bed``` can only be given one time and should be composed of the amplicon kit used to obtain the exome data.
The option ```regions_of_interest``` can contain multiple bed files in ```list``` format and can contain any region a user wants. If multiple regions are given,
the pipeline will make an coverage plot over each bed file separately.
### Modes ### Reporting modes
Shiva furthermore supports three modes. The default and recommended option is `multisample_variantcalling`. Shiva furthermore supports three modes. The default and recommended option is `multisample_variantcalling`.
During this mode, all bam files will be simultaneously called in one big VCF file. It will work with any number of samples. During this mode, all bam files will be simultaneously called in one big VCF file. It will work with any number of samples.
On top of that, Shiva provides two separate modes that only work with a single sample. Additionally, Shiva provides two separate modes that only work with a single sample.
Those are not recommended, but may be useful to those who need to validate replicates. Those are not recommended, but may be useful to those who need to validate replicates.
Mode `single_sample_variantcalling` calls a single sample as a merged bam file. Mode `single_sample_variantcalling` calls a single sample as a merged bam file.
...@@ -175,41 +160,81 @@ The config for these therefore is: ...@@ -175,41 +160,81 @@ The config for these therefore is:
| shiva | single_sample_variantcalling | Boolean | false | Not-recommended, single sample, merged bam | | shiva | single_sample_variantcalling | Boolean | false | Not-recommended, single sample, merged bam |
| shiva | library_variantcalling | Boolean | false | Not-recommended, single sample, per library | | shiva | library_variantcalling | Boolean | false | Not-recommended, single sample, per library |
## CNV calling ### Only variant calling
In addition to standard variant calling, Shiva also supports CNV calling. It is possible to run Shiva while only performing its variant calling steps starting from BAM files.
One can enable this option by setting the `cnv_calling` config option to `true`. This has been separated in its own pipeline named `shivavariantcalling`. Different than running shiva which converts BAM files to fastq files first,
shivavariantcalling will not perform any pre-processing and mapping steps. But just to call variants based on the input BAM files.
For CNV calling Shiva uses the [Kopisu](kopisu.md) as a module. To view the help menu, execute:
Please see the documentation for Kopisu. ~~~
biopet pipeline shivavariantcalling -h
Arguments for ShivaVariantcalling:
-BAM,--inputbamsarg <inputbamsarg> Bam files (should be deduped bams)
-sample,--sampleid <sampleid> Sample ID
-library,--libid <libid> Library ID
-config,--config_file <config_file> JSON / YAML config file(s)
-cv,--config_value <config_value> Config values, value should be formatted like 'key=value' or
'namespace:namespace:key=value'
-DSC,--disablescatter Disable all scatters
## Example configs ~~~
**Config example**
``` yaml To run the pipeline:
samples: ~~~
SampleID: biopet pipeline shivavariantcalling -config MySettings.yml -run
libraries: ~~~
lib_id_1:
bam: YourBam.bam ### Exome variant calling
lib_id_2:
R1: file_R1.fq.gz If one calls variants with Shiva on exome samples and an ```amplicon_bed``` file is available, the user is able to add this file to the config file.
R2: file_R2.fq.gz When the file is given, the coverage over the positions in the bed file will be calculated plus the number of variants on each position. If there is an interest
dbsnp: <dbsnp.vcf.gz> in a specific region of the genome/exome one is capable to give multiple ```regionOfInterest.bed``` files with the option ```regions_of_interest``` (in list/array format).
vcffilter:
min_alternate_depth: 1 A short recap: the option ```amplicon_bed``` can only be given one time and should be composed of the amplicon kit used to obtain the exome data.
output_dir: <output directory> The option ```regions_of_interest``` can contain multiple bed files in ```list``` format and can contain any region a user wants. If multiple regions are given,
variantcallers: the pipeline will make an coverage plot over each bed file separately.
- haplotypecaller
- unifiedgenotyper ### VEP annotation
- haplotypecaller_gvcf
unifiedgenotyper: Shiva can be linked to our VEP based annotation pipeline to annotate the VCF files.
merge_vcf_results: false # This will do the variantcalling but will not merged into the final vcf file
**example config**
```yaml
toucan:
vep_version: 86
enable_scatter: false
``` ```
**Additional XHMM CNV calling example** ### SV calling
In addition to standard variant calling, Shiva also supports SV calling.
One can enable this option by setting the `sv_calling` config option to `true`.
For SV calling Shiva uses the [yamsvp](yamsvp.md) as a sub-pipeline.
Please see the documentation for yamsvp.
**example config**
```yaml
shiva:
sv_calling: true
sv_callers:
- breakdancer
- delly
pysvtools:
flanking: 100
```
### CNV calling
In addition to standard variant calling, Shiva also supports CNV calling.
One can enable this option by setting the `cnv_calling` config option to `true`.
For CNV calling Shiva uses the [Kopisu](kopisu.md) as a sub-pipeline.
Please see the documentation for Kopisu.
**example config**
```yaml ```yaml
shiva: shiva:
cnv_calling: true cnv_calling: true
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment