Skip to content

Commit

Permalink
allow assembly to be passed in to plugin config
Browse files Browse the repository at this point in the history
  • Loading branch information
William McLaren committed Dec 5, 2017
1 parent b91e570 commit 33907b0
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion dbscSNV.pm
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,10 @@ sub new {
# get dbNSFP file
my $file = $self->params->[0];
$self->add_file($file);

if(my $assembly = $self->params->[1]) {
$self->{_param_assembly} = $assembly;
}

# get headers
open HEAD, "tabix -fh $file 1:1-1 2>&1 | ";
Expand Down Expand Up @@ -207,7 +211,7 @@ sub pos_column {

# work out which column to use
unless(exists($self->{pos_column})) {
if(my $assembly = $self->{config}->{assembly}) {
if(my $assembly = $self->{_param_assembly} || $self->{config}->{assembly}) {
if($assembly eq 'GRCh37') {
$self->{pos_column} = 'pos';
}
Expand Down

0 comments on commit 33907b0

Please sign in to comment.