diff options
author | Thomas White <taw@physics.org> | 2013-03-21 12:20:11 +0100 |
---|---|---|
committer | Thomas White <taw@physics.org> | 2013-03-21 12:20:11 +0100 |
commit | 5586bde15ca4b023816f37b53c6d173c1ab50b7b (patch) | |
tree | c9ddf11dd97240250b7be527cdab98c2a6a5cf21 /scripts/check-near-bragg | |
parent | e170dd8566db74784b457114ba8090982939411a (diff) |
scripts/check-{near-bragg,peak-detection}: Improve option processing
Diffstat (limited to 'scripts/check-near-bragg')
-rwxr-xr-x | scripts/check-near-bragg | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/scripts/check-near-bragg b/scripts/check-near-bragg index 5ebae9b1..27a1d61c 100755 --- a/scripts/check-near-bragg +++ b/scripts/check-near-bragg @@ -3,6 +3,15 @@ use strict; use File::Basename; +my $args = join(" ", splice(@ARGV, 1, scalar(@ARGV)-1)); +if ( !($args eq "") ) { + printf("Extra arguments for hdfsee: %s\n", $args); +} else { + # Default arguments - feel free to override! + $args = "--binning=2 --int-boost=10"; + printf("Using default arguments for hdfsee: %s\n", $args); +} + open(FH, $ARGV[0]); open(TMP, "> list.tmp"); @@ -38,7 +47,7 @@ while ( $line = <FH> ) { printf(STDERR "Viewing %s\n", $filename); system("hdfsee ".$filename. - " --peak-overlay=list.tmp --binning=2 --int-boost=10"); + " --peak-overlay=list.tmp ".$args); if ( $? != 0 ) { exit; } unlink("list.tmp"); open(TMP, "> list.tmp"); |