def METHOD_NAME(tree, region: int, station: int, output_dir: Path):
    expressions = [
        'region',
        'station',
        'chamber',
        'csc_is_muon',
        'gem_layer'
    ]
    cut_list = [
        f'region == {region}',
        f'station == {station}',
        'ring == 1',
        'csc_num_hit == 6',
        '~gem_chamber_has_error',
    ]
    cut = ' & '.join(f'({each})' for each in cut_list)
    num_chambers = 36 if station == 1 else 18
    chamber_axis = hist.axis.Regular(num_chambers, 0.5, num_chambers + 0.5, name='chamber', label='Chamber')
    muon_axis = hist.axis.hist.axis.Boolean(name='muon')
    # has a csc segment
    h_csc = hist.Hist(chamber_axis, muon_axis, storage=hist.storage.Int64())
    # has a CSC segment and a hit on L1(L2) layer
    h_l1 = h_csc.copy()
    h_l2 = h_csc.copy()
    # has a csc segment and hits on both layers
    h_both = h_csc.copy()
    for chunk in tree.iterate(expressions, cut=cut):
        has_l1 = ak.any(chunk.gem_layer == 1, axis=1)
        has_l2 = ak.any(chunk.gem_layer == 2, axis=1)
        has_both = has_l1 & has_l2
        h_csc.fill(chamber=chunk.chamber, muon=chunk.csc_is_muon)
        h_l1.fill(chamber=chunk.chamber[has_l1], muon=chunk.csc_is_muon[has_l1])
        h_l2.fill(chamber=chunk.chamber[has_l2], muon=chunk.csc_is_muon[has_l2])
        h_both.fill(chamber=chunk.chamber[has_both], muon=chunk.csc_is_muon[has_both])
    # twofold efficiencies
    eff_l1_twofold_all = Efficiency1D.from_hist(h_num=h_l1.project(0), h_den=h_csc.project(0))
    eff_l2_twofold_all = Efficiency1D.from_hist(h_num=h_l2.project(0), h_den=h_csc.project(0))
    # threefold efficiencies
    eff_l1_threefold_all = Efficiency1D.from_hist(h_num=h_both.project(0), h_den=h_l2.project(0))
    eff_l2_threefold_all = Efficiency1D.from_hist(h_num=h_both.project(0), h_den=h_l1.project(0))
    # efficiencies
    muon_mask = (slice(None), True)
    eff_l1_twofold_muon = Efficiency1D.from_hist(h_num=h_l1[muon_mask], h_den=h_csc[muon_mask])
    eff_l2_twofold_muon = Efficiency1D.from_hist(h_num=h_l2[muon_mask], h_den=h_csc[muon_mask])
    eff_l1_threefold_muon = Efficiency1D.from_hist(h_num=h_both[muon_mask], h_den=h_l2[muon_mask])
    eff_l2_threefold_muon = Efficiency1D.from_hist(h_num=h_both[muon_mask], h_den=h_l1[muon_mask])
    plot_eff(eff_twofold_all=eff_l1_twofold_all,
             eff_twofold_muon=eff_l1_twofold_muon,
             eff_threefold_all=eff_l1_threefold_all,
             eff_threefold_muon=eff_l1_threefold_muon,
             gem_lable=name_gem_layer(region, station, layer=1),
             output_dir=output_dir)
    plot_eff(eff_twofold_all=eff_l2_twofold_all,
             eff_twofold_muon=eff_l2_twofold_muon,
             eff_threefold_all=eff_l2_threefold_all,
             eff_threefold_muon=eff_l2_threefold_muon,
             gem_lable=name_gem_layer(region, station, layer=2),
             output_dir=output_dir)