7 gSystem->mkdir(
"result",
true);
19 TTimeStamp ts0(2024, 2, 8, 18, 0, 0);
20 int utime0 = ts0.GetSec() + TTimeStamp::GetZoneOffset();
25 TGraph* gr_pol =
new TGraph();
26 TGraph* gr_pres =
new TGraph();
29 for (
int i_evt = 0; i_evt < n_evt; i_evt++) {
31 int evt_num = evt->
GetInt (
"EventNum");
32 double pol = evt->
GetDouble(
"Polarization");
34 string qmeter = evt->
GetString(
"QMeterName");
38 if (utime0 == 0) utime0 = evt_num;
39 if (evt_num < utime0)
continue;
41 int n_pt = gr_pol->GetN();
42 double time = (evt_num - utime0) / 3600.0;
43 gr_pol ->SetPoint(n_pt, time, pol );
44 gr_pres->SetPoint(n_pt, time, pres);
50 TCanvas* c1 =
new TCanvas(
"c1",
"");
54 gr_pol->SetMarkerStyle(7);
56 c1->SaveAs(
"result/gr_pol.png");
59 gr_pres->SetMarkerStyle(7);
61 gr_pres->GetYaxis()->SetRangeUser(21.0, 26.0);
62 c1->SaveAs(
"result/gr_pres.png");
void ReadEventFile(const std::string label)
NMREvent * GetEvent(const int index)
void PrintKeyList(std::ostream &os=std::cout)
std::string GetString(const int idx)
double GetDouble(const int idx)
int GetInt(const int idx)
void ConvEventNum(const int event_num, int &YYYY, int &MM, int &DD, int &hh, int &mm, int &ss)