Analysis.py
1.08 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
#!/bin/python
from sys import argv
from numpy import shape
from Modules.Spectrum import drawSpectrum
from Modules.Angle import drawAngle, drawRadial
from Modules.Timing import drawTiming
from Modules.Generation import drawGeneration
from Modules.Map import drawMap, drawMapHisto
if shape(argv)[0] < 3:
print "Give at least 2 arguments"
print "first argument could be:"
print " - spectrum (flux versus energy)"
print " - angle (angle versus energy)"
print " - radial (angular distrubution)"
print " - timing (time distrubution)"
print " - generation (generation histogram)"
print " - maphisto"
print " - map"
print "others arguments are the folders files to plot"
exit()
if argv[1] == "spectrum":
drawSpectrum(argv[2:])
elif argv[1] == "angle":
drawAngle(argv[2:])
elif argv[1] == "radial":
drawRadial(argv[2:])
elif argv[1] == "timing":
drawTiming(argv[2:])
elif argv[1] == "generation":
drawGeneration(argv[2:])
elif argv[1] == "maphisto":
drawMapHisto(argv[2:])
elif argv[1] == "map":
drawMap(argv[2:])
else:
print "bad 1st argument"