Jpp  15.0.2
the software that should make you happy
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
JCharge.sh
Go to the documentation of this file.
1 #!/bin/zsh
2 #
3 # \author mdejong & bjjung
4 #
5 version=1.0
6 script=${0##*/}
7 
8 # ------------------------------------------------------------------------------------------
9 #
10 # Utility script to plot charge distribution from JDETECTOR::JPMTDefaultSignalProcessor.
11 #
12 # ------------------------------------------------------------------------------------------
13 
14 
15 if [ -z $JPP_DIR ]; then
16  echo "Variable JPP_DIR undefined."
17  exit
18 fi
19 
20 
21 source $JPP_DIR/setenv.sh $JPP_DIR
22 
23 
27 set_variable PMT_FILE "gain=0.9"
28 set_variable NPE 1
29 set_variable xrange "0 $((3*NPE))"
30 
31 
32 if do_usage $*; then
33  usage "$script [output file] [pmt file]"
34 fi
35 
36 case $# in
37  2) set_variable PMT_FILE $2;&
39 esac
40 
41 
42 if (( 1 )); then
43 
44  $JPP_DIR/examples/JDetector/JCharge \
45  -o $OUTPUT_FILE \
46  -n 999999 \
47  -N $NPE \
48  -P $PMT_FILE \
49  -d $DEBUG
50 
51 fi
52 
53 if (( 0 )); then
54 
55  JPlot1D \
56  -f ${OUTPUT_FILE}:h0 \
57  -f ${OUTPUT_FILE}:h1 \
58  -x $xrange \
59  -\> "Charge [npe]" \
60  -\^ "Probability density [npe^{-1}]" \
61  -S 0.4 \
62  -y "1e-3 1.1" --
63 
64 fi
65 
66 if (( 0 )); then
67 
68  JSum1D \
69  -f ${OUTPUT_FILE}:h0 \
70  -f ${OUTPUT_FILE}:h1 \
71  -o $WORKDIR/sum.root
72 
73  JPlot1D \
74  -f $WORKDIR/sum.root:h0 \
75  -f $WORKDIR/sum.root:h1 \
76  -x $xrange \
77  -\> "Charge [npe]" \
78  -\^ "Probability" \
79  -S 0.4 \
80  -G XY \
81  -y "1e-3 1.1" -Y --
82 
83 fi
then JMuonPostfit f
then usage $script< detector file >< inputfile > nUtility script to create PDF and CDF of transition time distribution fi case set_variable WORKDIR
Definition: JLegolas.sh:31
then JShowerPostfit f $INPUT_FILE o $OUTPUT_FILE N
exit
Definition: JPizza.sh:36
then for HISTOGRAM in h0 h1
Definition: JMatrixNZ.sh:71
then fatal Wrong number of arguments fi set_variable STRING $argv[1] set_variable DETECTORXY_TXT $WORKDIR $DETECTORXY_TXT tail read X Y CHI2 RMS printf optimum n $X $Y $CHI2 $RMS awk v Y
then echo
const int n
Definition: JPolint.hh:660
then echo Variable JPP_DIR undefined exit fi source $JPP_DIR setenv sh $JPP_DIR &dev null set_variable
Definition: JAcoustics.sh:20
do $DIR JTransitTime o
Definition: JTransitTime.sh:44
* usage
do set_variable SIGMA_NS set_variable OUTLIERS set_variable OUTPUT_FILE matrix[${ALPHA_DEG}\deg\] root $JPP JMatrixNZ a $DETECTOR f $INPUT_FILE o $OUTPUT_FILE S
Definition: JMatrixNZ.sh:58
&set_variable OUTPUT_FILE
then JMuonMCEvt f $INPUT_FILE o $INTERMEDIATE_FILE d
Definition: JMuonPath.sh:47
then usage $script< input_file >< detector_file > fi set_variable OUTPUT_DIR set_variable SELECTOR JDAQTimesliceL1 set_variable DEBUG case set_variable DEBUG
then display $WORKDIR
Definition: plot-Domino.sh:128
then fatal Wrong number of arguments fi set_variable DETECTOR $argv[1] set_variable INPUT_FILE $argv[2] eval JPrintDetector a $DETECTOR O IDENTIFIER eval JPrintDetector a $DETECTOR O SUMMARY source JAcoustics sh $DETECTOR_ID CHECK_EXIT_CODE typeset A TRIPODS get_tripods $WORKDIR tripod txt TRIPODS for EMITTER in
Definition: JCanberra.sh:41
version
Definition: JCalibratePMT.sh:7
then $DIR JPlotNPE PDG P
Definition: JPlotNPE-PDG.sh:62