Jpp test-rotations-new
the software that should make you happy
Loading...
Searching...
No Matches
JTransitTime2D.sh
Go to the documentation of this file.
1#!/usr/bin/env zsh
2#
3# \author mdejong
4#
5version=1.0
6script=${0##*/}
7
8# ------------------------------------------------------------------------------------------
9#
10# Utility script to plot transition time spread from JDETECTOR::JPMTAnalogueSignaProcessor.
11#
12# ------------------------------------------------------------------------------------------
13
14
15if [ -z $JPP_DIR ]; then
16 echo "Variable JPP_DIR undefined."
17 exit
18fi
19
20
21source $JPP_DIR/setenv.sh $JPP_DIR
22
23
24set_variable DEBUG 3
25set_variable WORKDIR ${TMPDIR:-/tmp}/
26set_variable DIR $JPP_DIR/examples/JDetector
27set_variable OUTPUT_FILE $WORKDIR/tt2.root
28
29
30if do_usage $*; then
31 usage "$script [output file]"
32fi
33
34case $# in
35 1) set_variable OUTPUT_FILE $1;;
36esac
37
38$DIR/JTransitTime2D \
39 -o $OUTPUT_FILE \
40 -d $DEBUG
41
42JFit \
43 -f ${OUTPUT_FILE}:tt2 \
44 -F "[0]*exp(-0.5*(x-[1])*(x-[1])/([2]*[2]))" \
45 -@ "p0 = 0.8*GetMaximum" \
46 -@ "p1 = 0.0" \
47 -@ "p2 = 2.0" \
48 -o $WORKDIR/fit.root
49
50JPlot1D \
51 -f $WORKDIR/fit.root:tt2 \
52 -> "time [ns]" \
53 -\^ "number of events [au]" \