55 myntuple = eFEXNTupleLoader(path)
57 selected_l_ET_TLV = []
58 selected_l_eta_TLV = []
59 selected_l_ET_Oregon = []
60 selected_l_eta_Oregon = []
62 for each
in myntuple.entries():
63 each.set_class_type(
"tau")
64 if each.leading_l_id()
is None:
68 if each.is_in_crack(each.leading_l_id()):
70 if abs(each.truth_tauvisible_eta[each.leading_l_id()]) > 2.3:
74 all_l_ET.append(each.truth_tauvisible_ET[each.leading_l_id()])
75 all_l_eta.append(each.truth_tauvisible_eta[each.leading_l_id()])
76 matched_tobs = each.get_eg_matchedtob_id()[each.leading_l_id()]
78 oregon_selected =
False
79 for i
in matched_tobs:
80 if each.eg_tauTLV_Et[i] <= 12:
82 if each.eg_tauTLV_Iso[i] < 0.66
and each.eg_tauTLV_Et[i] <= 15:
86 for i
in matched_tobs:
87 if each.eg_tauOregon_Et[i] <= 12:
89 if each.eg_tauOregon_Iso[i] < 0.66
and each.eg_tauOregon_Et[i] <= 15:
91 oregon_selected =
True
94 selected_l_ET_TLV.append(each.truth_tauvisible_ET[each.leading_l_id()])
97 selected_l_ET_Oregon.append(each.truth_tauvisible_ET[each.leading_l_id()])
99 hist_height, bin_centre, hist_error =
turn_on_curve(all_l_ET, selected_l_ET_TLV,
range(0,100,5))
100 histplot([bin_centre], [hist_height], [hist_error], errorbar_limit=1, filename=
"tautlvtrunon")
101 hist_height, bin_centre, hist_error =
turn_on_curve(all_l_ET, selected_l_ET_Oregon,
range(0,100,5))
102 histplot([bin_centre], [hist_height], [hist_error], errorbar_limit=1, filename=
"tauoregontrunon")