source: fact/tools/pyscripts/sandbox/qw.py@ 13397

Last change on this file since 13397 was 13394, checked in by neise, 13 years ago
test von qw
File size: 895 bytes
Line 
1#!/usr/bin/python -itt
2
3
4from factfits import FactFits
5from ROOT import TCanvas, TGraph
6
7#define filenames
8data_filename_1 =
9"/fact/aux/2012/04/17/20120417_030.FTM_CONTROL_TRIGGER_RATES.fits"
10#data_filename_2 =
11"/fact/aux/2012/04/17/20120417_031.FTM_CONTROL_TRIGGER_RATES.fits"
12
13file_handle_1 = FactFits(data_filename_1)
14#file_handle_2 = FactFits(data_filename_2)
15
16file_handle_1.register("TriggerRate")
17file_handle_1.register("Time")
18#file_handle_2.register("TriggerRate")
19#file_handle_2.register("Time")
20
21trigger_rate_array = []
22time_array = []
23
24for row in file_handle_1:
25 trigger_rate_array.append(row.TriggerRate)
26 time_array.append(row.Time)
27
28#for row in file_handle_2:
29# trigger_rate_array.append(row.TriggerRate)
30# time_array.append(row.Time)
31
32canv = TCanvas("canv","title",10,10,600,400)
33graph = TGraph(len(trigger_rate_array),time_array,trigger_rate_array)
34graph.Draw("ap")
35
Note: See TracBrowser for help on using the repository browser.