import numpy as np from numpy import nan add_legend_handle = [ 'alpha2.yoda', '_alpha2.yoda' ] xpoints = { 'alpha2.yoda' : [-52.82, -47.26, -41.7, -36.14, -30.58, -25.02, -19.46, -13.899999999999999, -8.34, -2.7799999999999963, 2.7800000000000034, 8.34, 13.899999999999999, 19.46, 25.02, 30.58, 36.14, 41.7, 47.26, 52.82], '_alpha2.yoda' : [-52.82, -47.26, -41.7, -36.14, -30.58, -25.02, -19.46, -13.899999999999999, -8.34, -2.779999999999992, 2.780000000000008, 8.34, 13.899999999999999, 19.46, 25.02, 30.58, 36.14, 41.7, 47.26, 52.82], } xedges = { 'alpha2.yoda' : [-55.6, -50.04, -44.48, -38.92, -33.36, -27.8, -22.24, -16.68, -11.12, -5.56, 7.105427357601002e-15, 5.56, 11.12, 16.68, 22.24, 27.8, 33.36, 38.92, 44.48, 50.04, 55.6], '_alpha2.yoda' : [-55.6, -50.04, -44.48, -38.92, -33.36, -27.8, -22.24, -16.68, -11.12, -5.56, 1.5987211554602254e-14, 5.56, 11.12, 16.68, 22.24, 27.8, 33.36, 38.92, 44.48, 50.04, 55.6], } ref_xerrs = [ [abs(xpoints['alpha2.yoda'][i] - xedges['alpha2.yoda'][i]) for i in range(len(xpoints['alpha2.yoda']))], [abs(xedges['alpha2.yoda'][i+1] - xpoints['alpha2.yoda'][i]) for i in range(len(xpoints['alpha2.yoda']))] ] yvals = { 'alpha2.yoda' : [0.0, 4.031192446043164, 21.32521582733815, 19.631924460431645, 17.793149280575545, 16.153580935251792, 14.810483812949643, 13.802021582733811, 13.16348021582734, 12.973050359712214, 12.98703956834534, 13.175291366906476, 13.819818345323739, 14.821456834532379, 16.170104316546755, 17.801080935251804, 19.6240107913669, 21.21825539568347, 3.958370503597121, 0.0], '_alpha2.yoda' : [0.0, 4.035558, 21.32841, 19.64421, 17.78461, 16.15538, 14.80433, 13.79853, 13.16142, 12.97679, 12.98184, 13.17402, 13.81985, 14.82149, 16.16892, 17.80302, 19.63374, 21.21521, 3.958444, 0.0], } xerrs = { 'alpha2.yoda' : [ [2.780000000000001, 2.780000000000001, 2.780000000000001, 2.780000000000001, 2.7799999999999976, 2.780000000000001, 2.780000000000001, 2.7799999999999994, 2.7800000000000002, 2.7800000000000034, 2.7799999999999963, 2.7799999999999994, 2.780000000000001, 2.7799999999999976, 2.780000000000001, 2.780000000000001, 2.780000000000001, 2.779999999999994, 2.780000000000001, 2.780000000000001], [2.780000000000001, 2.780000000000001, 2.779999999999994, 2.780000000000001, 2.780000000000001, 2.780000000000001, 2.7799999999999976, 2.780000000000001, 2.7799999999999994, 2.7800000000000034, 2.7799999999999963, 2.7800000000000002, 2.7799999999999994, 2.780000000000001, 2.780000000000001, 2.7799999999999976, 2.780000000000001, 2.780000000000001, 2.780000000000001, 2.780000000000001], ], '_alpha2.yoda' : [ [2.780000000000001, 2.780000000000001, 2.780000000000001, 2.780000000000001, 2.7799999999999976, 2.780000000000001, 2.780000000000001, 2.7799999999999994, 2.7800000000000002, 2.780000000000008, 2.779999999999992, 2.7799999999999994, 2.780000000000001, 2.7799999999999976, 2.780000000000001, 2.780000000000001, 2.780000000000001, 2.779999999999994, 2.780000000000001, 2.780000000000001], [2.780000000000001, 2.780000000000001, 2.779999999999994, 2.780000000000001, 2.780000000000001, 2.780000000000001, 2.7799999999999976, 2.780000000000001, 2.7799999999999994, 2.780000000000008, 2.779999999999992, 2.7800000000000002, 2.7799999999999994, 2.780000000000001, 2.780000000000001, 2.7799999999999976, 2.780000000000001, 2.780000000000001, 2.780000000000001, 2.780000000000001], ], } yerrs = { 'alpha2.yoda' : [ [0.0, 0.34071190695393866, 1.8023171213325817, 1.6592125806743752, 1.503805039667487, 1.365236342429369, 1.2517241357185602, 1.1664967645133006, 1.1125292184205542, 1.0964352430597462, 1.097614584684718, 1.1135252170404775, 1.1679996531649695, 1.252652457254486, 1.3666326401212845, 1.5044774280991566, 1.6585436311255057, 1.7932820906924567, 0.33455306658367406, 0.0], [0.0, 0.34071190695393866, 1.8023171213325817, 1.6592125806743752, 1.503805039667487, 1.365236342429369, 1.2517241357185602, 1.1664967645133006, 1.1125292184205542, 1.0964352430597462, 1.097614584684718, 1.1135252170404775, 1.1679996531649695, 1.252652457254486, 1.3666326401212845, 1.5044774280991566, 1.6585436311255057, 1.7932820906924567, 0.33455306658367406, 0.0], ], '_alpha2.yoda' : [ [0.0, 0.001468718, 0.003376494, 0.00324044, 0.003083251, 0.002938633, 0.002813074, 0.002715833, 0.002652394, 0.002633724, 0.002634237, 0.002653664, 0.002717931, 0.002814704, 0.002939864, 0.003084846, 0.003239576, 0.003367521, 0.001454618, 0.0], [0.0, 0.001468718, 0.003376494, 0.00324044, 0.003083251, 0.002938633, 0.002813074, 0.002715833, 0.002652394, 0.002633724, 0.002634237, 0.002653664, 0.002717931, 0.002814704, 0.002939864, 0.003084846, 0.003239576, 0.003367521, 0.001454618, 0.0], ], } variation_yvals = { } # lists for ratio plot ratio0_yvals = { 'alpha2.yoda' : [1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0], '_alpha2.yoda' : [1.0, 1.0010829435744555, 1.0001497838374869, 1.0006257939507213, 0.9995200804286588, 1.0001113725034356, 0.9995844961564144, 0.9997470238172805, 0.9998434900350393, 1.0002882622193003, 0.9995996340568629, 0.9999035036971046, 1.0000022905276662, 1.0000022376658375, 0.9999267588802415, 1.0001089296068733, 1.000495780844015, 0.9998564728519531, 1.000018567337952, 1.0], } ratio0_yerrs = { 'alpha2.yoda' : [ [1.0, 0.08451888901716068, 0.08451577399850167, 0.08451604344844216, 0.08451595700987927, 0.0845160183306494, 0.08451608681575325, 0.0845163701216477, 0.08451634371607027, 0.08451637915973285, 0.08451615003622905, 0.08451617395251049, 0.08451628118253737, 0.08451614920443867, 0.08451600641331787, 0.08451607144371849, 0.08451603745831313, 0.08451600083281458, 0.0845178757975417, 1.0], [1.0, 0.08451888901716068, 0.08451577399850167, 0.08451604344844216, 0.08451595700987927, 0.0845160183306494, 0.08451608681575325, 0.0845163701216477, 0.08451634371607027, 0.08451637915973285, 0.08451615003622905, 0.08451617395251049, 0.08451628118253737, 0.08451614920443867, 0.08451600641331787, 0.08451607144371849, 0.08451603745831313, 0.08451600083281458, 0.0845178757975417, 1.0], ], '_alpha2.yoda' : [ [1.0, 0.0003643383489274066, 0.0001583334033914657, 0.00016505972231765367, 0.00017328304008363087, 0.00018191836297963207, 0.00018993802198010376, 0.00019677066752289964, 0.00020149640949897491, 0.0002030150139691915, 0.00020283583384320315, 0.00020141216813355934, 0.00019666908291306707, 0.00018990737762309887, 0.00018180859829034358, 0.00017329543139658579, 0.00016508225736530739, 0.0001587086655901536, 0.00036747899133699933, 1.0], [1.0, 0.0003643383489274066, 0.0001583334033914657, 0.00016505972231765367, 0.00017328304008363087, 0.00018191836297963207, 0.00018993802198010376, 0.00019677066752289964, 0.00020149640949897491, 0.0002030150139691915, 0.00020283583384320315, 0.00020141216813355934, 0.00019666908291306707, 0.00018990737762309887, 0.00018180859829034358, 0.00017329543139658579, 0.00016508225736530739, 0.0001587086655901536, 0.00036747899133699933, 1.0], ], } ratio0_variation_vals = { } ratio_band_edges = { }