Skip to content

Commit

Permalink
Merge 8fe83f9 into 53a6616
Browse files Browse the repository at this point in the history
  • Loading branch information
jemten committed Apr 18, 2023
2 parents 53a6616 + 8fe83f9 commit 8f99193
Show file tree
Hide file tree
Showing 8 changed files with 550 additions and 27 deletions.
1 change: 1 addition & 0 deletions definitions/rd_dna_initiation_map.yaml
Expand Up @@ -54,6 +54,7 @@ CHAIN_ALL:
- retroseq
- me_merge_vcfs
- me_annotate
- me_varianteffectpredictor
- CHAIN_MAIN:
# PARALLEL chains, which inherit from MAIN in initiation, but are merged back to CHAIN_MAIN after execution
- PARALLEL:
Expand Down
15 changes: 15 additions & 0 deletions definitions/rd_dna_parameters.yaml
Expand Up @@ -229,6 +229,7 @@ recipe_core_number:
me_annotate: 2
me_merge_bam: 5
me_merge_vcfs: 2
me_varianteffectpredictor: 4
mitodel: 1
mt_annotation: 1
multiqc_ar: 1
Expand Down Expand Up @@ -363,6 +364,7 @@ recipe_time:
me_annotate: 2
me_merge_bam: 5
me_merge_vcfs: 2
me_varianteffectpredictor: 3
mitodel: 2
mt_annotation: 1
multiqc_ar: 5
Expand Down Expand Up @@ -1359,6 +1361,19 @@ me_annotate_exons_bed:
is_reference: 1
reference: reference_dir
type: path
me_varianteffectpredictor:
analysis_mode: case
associated_recipe:
- mip
data_type: SCALAR
default: 1
file_tag: _vep
outfile_suffix: ".vcf.gz"
program_executables:
- bcftools
- tabix
- vep
type: recipe
## GATK CollectReadCounts
gatk_collectreadcounts:
analysis_mode: sample
Expand Down
9 changes: 9 additions & 0 deletions lib/MIP/Cli/Mip/Analyse/Rd_dna.pm
Expand Up @@ -1245,6 +1245,15 @@ q{Default: hgvs, symbol, numbers, sift, polyphen, humdiv, domains, protein, ccds
)
);

option(
q{me_varianteffectpredictor} => (
cmd_tags => [q{Analysis recipe switch}],
documentation => q{Annotate mobile elements with VEP},
is => q{rw},
isa => enum( [ 0, 1, 2 ] ),
)
);

option(
q{gatk_haplotypecaller} => (
cmd_tags => [q{Analysis recipe switch}],
Expand Down
23 changes: 16 additions & 7 deletions lib/MIP/Program/Vep.pm
Expand Up @@ -39,6 +39,7 @@ sub variant_effect_predictor {
## Arguments: $assembly => Assembly version to use
## : $buffer_size => Sets the internal buffer size, corresponding to the number of variants that are read in to memory simultaneously
## : $cache_directory => VEP chache directory
## : $compress_output => Compress output
## : $custom_annotations_ref => Custom annotations {REF}
## : $distance => Modify the distance up and/or downstream between a variant and a transcript for which VEP will assign the upstream_gene_variant or downstream_gene_variant consequences
## : $filehandle => Filehandle to write to
Expand All @@ -65,6 +66,7 @@ sub variant_effect_predictor {
my $assembly;
my $buffer_size;
my $cache_directory;
my $compress_output;
my $custom_annotations_ref;
my $filehandle;
my $infile_path;
Expand Down Expand Up @@ -102,6 +104,11 @@ sub variant_effect_predictor {
store => \$cache_directory,
strict_type => 1,
},
compress_output => {
allow => [ undef, 0, 1 ],
store => \$compress_output,
strict_type => 1,
},
custom_annotations_ref => {
default => [],
store => \$custom_annotations_ref,
Expand Down Expand Up @@ -225,6 +232,10 @@ sub variant_effect_predictor {

push @commands, q{--dir_cache} . $SPACE . $cache_directory;
}
if ($compress_output) {

push @commands, q{--compress_output} . $SPACE . q{bgzip};
}
if ($infile_format) {

push @commands, q{--format} . $SPACE . $infile_format;
Expand Down Expand Up @@ -259,8 +270,7 @@ sub variant_effect_predictor {
}
if ( @{$custom_annotations_ref} ) {

push @commands, q{--custom} . $SPACE . join q{ --custom },
@{$custom_annotations_ref};
push @commands, q{--custom} . $SPACE . join q{ --custom }, @{$custom_annotations_ref};
}
if ( @{$vep_features_ref} ) {

Expand Down Expand Up @@ -353,11 +363,10 @@ sub variant_effect_predictor_install {
store => \$species_ref,
strict_type => 1,
},
stderrfile_path => { store => \$stderrfile_path, strict_type => 1, },
stderrfile_path_append =>
{ store => \$stderrfile_path_append, strict_type => 1, },
stdoutfile_path => { store => \$stdoutfile_path, strict_type => 1, },
version => { store => \$version, strict_type => 1, },
stderrfile_path => { store => \$stderrfile_path, strict_type => 1, },
stderrfile_path_append => { store => \$stderrfile_path_append, strict_type => 1, },
stdoutfile_path => { store => \$stdoutfile_path, strict_type => 1, },
version => { store => \$version, strict_type => 1, },
};

check( $tmpl, $arg_href, 1 ) or croak q{Could not parse arguments!};
Expand Down

0 comments on commit 8f99193

Please sign in to comment.