Jpp  master_rocky-37-gf0c5bc59d
the software that should make you happy
hydrophone-t0:plot.sh
Go to the documentation of this file.
1 #!/bin/zsh
2 script=${0##*/}
3 
4 if [ -z $JPP_DIR ]; then
5  echo "Variable JPP_DIR undefined."
6  exit
7 fi
8 
9 source $JPP_DIR/setenv.sh $JPP_DIR >& /dev/null
10 
11 zmodload zsh/mathfunc
12 
13 set_variable: DEBUG ACOUSTICS_DEBUG 2
14 set_variable: WORKDIR ACOUSTICS_WORKDIR ./
15 set_variable: XMIN HYDROPHONE_XMIN -1.0e-3
16 set_variable: XMAX HYDROPHONE_XMAX +1.0e-3
17 set_variable: FORMAT GRAPHICS_FORMAT gif
18 set_variable+ BATCH GRAPHICS_BATCH -B
19 
20 if do_usage $*; then
21  usage "$script <detector file> <string identifier>"
22 fi
23 
24 if (( $# != 2 )); then
25  fatal "Wrong number of arguments."
26 fi
27 
28 set_variable DETECTOR $argv[1]
29 set_variable STRING $argv[2]
30 set_variable MODULE `getModule -a $DETECTOR -L "$STRING 0"`
31 
32 typeset -Z 4 STRING
33 
34 JPlot1D \
35  -f hydrophone.root:$MODULE \
36  -x "$XMIN $XMAX" \
37  -> "#Deltat [s]" \
38  -\^ "number of events [a.u.]" \
39  -N "X 505" \
40  -L TR \
41  -T "$STRING" \
42  -o hydrophonet0_${STRING}.$FORMAT $BATCH