import numpy as np from numpy import nan add_legend_handle = [ 'alpha0.yoda', '_alpha0.yoda' ] xpoints = { 'alpha0.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], '_alpha0.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 = { 'alpha0.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], '_alpha0.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['alpha0.yoda'][i] - xedges['alpha0.yoda'][i]) for i in range(len(xpoints['alpha0.yoda']))], [abs(xedges['alpha0.yoda'][i+1] - xpoints['alpha0.yoda'][i]) for i in range(len(xpoints['alpha0.yoda']))] ] yvals = { 'alpha0.yoda' : [0.0, 4.286638489208632, 21.2879676258993, 19.045233812949633, 16.98684352517986, 15.270552158273375, 13.906507194244606, 12.871566546762589, 12.216116906474822, 11.96300719424459, 11.95868705035973, 12.192406474820144, 12.832152877697842, 13.839100719424465, 15.208300359712224, 16.930586330935256, 19.003741007194236, 21.354334532374118, 4.36570323741007, 0.0], '_alpha0.yoda' : [0.0, 4.286388, 21.28685, 19.0462, 16.99476, 15.26925, 13.89418, 12.87069, 12.21825, 11.96749, 11.96256, 12.1954, 12.83299, 13.84143, 15.21158, 16.93463, 18.99586, 21.3549, 4.365234, 0.0], } xerrs = { 'alpha0.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], ], '_alpha0.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 = { 'alpha0.yoda' : [ [0.0, 0.3622976779141373, 1.7991698610220517, 1.6096281277012665, 1.4356617127981561, 1.2906075551438307, 1.1753241395375404, 1.08785536709881, 1.032460578435062, 1.0110684737544495, 1.0107036752457794, 1.0304557854763323, 1.0845261104368318, 1.1696281155030115, 1.2853453475187413, 1.430906473626505, 1.6061179276039275, 1.804780613390695, 0.36898046389180666, 0.0], [0.0, 0.3622976779141373, 1.7991698610220517, 1.6096281277012665, 1.4356617127981561, 1.2906075551438307, 1.1753241395375404, 1.08785536709881, 1.032460578435062, 1.0110684737544495, 1.0107036752457794, 1.0304557854763323, 1.0845261104368318, 1.1696281155030115, 1.2853453475187413, 1.430906473626505, 1.6061179276039275, 1.804780613390695, 0.36898046389180666, 0.0], ], '_alpha0.yoda' : [ [0.0, 0.001480064, 0.003298302, 0.003119887, 0.002947083, 0.002793468, 0.002664718, 0.002564695, 0.002498845, 0.002473069, 0.00247256, 0.002496507, 0.002560936, 0.002659654, 0.002788187, 0.002941864, 0.003115762, 0.00330357, 0.001493615, 0.0], [0.0, 0.001480064, 0.003298302, 0.003119887, 0.002947083, 0.002793468, 0.002664718, 0.002564695, 0.002498845, 0.002473069, 0.00247256, 0.002496507, 0.002560936, 0.002659654, 0.002788187, 0.002941864, 0.003115762, 0.00330357, 0.001493615, 0.0], ], } variation_yvals = { } # lists for ratio plot ratio0_yvals = { 'alpha0.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], '_alpha0.yoda' : [1.0, 0.9999415651193208, 0.9999474996430407, 1.0000507311729463, 1.000466035659209, 0.9999147274925045, 0.9991135664712627, 0.9999319005375605, 1.0001746130576115, 1.0003747223154364, 1.0003238607736753, 1.0002455237352887, 1.000065236309927, 1.000168311555986, 1.0002156480481188, 1.0002388380996206, 0.9995852918016904, 1.0000264802270016, 0.9998925173369437, 1.0], } ratio0_yerrs = { 'alpha0.yoda' : [ [1.0, 0.08451789877457618, 0.08451581159082333, 0.08451606021275594, 0.08451609686461482, 0.08451610274253228, 0.08451612781849091, 0.08451615917507908, 0.08451626538444751, 0.08451624723931248, 0.08451627431920934, 0.08451619355083329, 0.0845163021960039, 0.08451619358917806, 0.08451604170862542, 0.084516061384831, 0.08451588174117403, 0.08451589117209753, 0.0845179903045133, 1.0], [1.0, 0.08451789877457618, 0.08451581159082333, 0.08451606021275594, 0.08451609686461482, 0.08451610274253228, 0.08451612781849091, 0.08451615917507908, 0.08451626538444751, 0.08451624723931248, 0.08451627431920934, 0.08451619355083329, 0.0845163021960039, 0.08451619358917806, 0.08451604170862542, 0.084516061384831, 0.08451588174117403, 0.08451589117209753, 0.0845179903045133, 1.0], ], '_alpha0.yoda' : [ [1.0, 0.0003452738092390988, 0.00015493738331259159, 0.0001638145811514617, 0.0001734920908426273, 0.00018293169566147856, 0.00019161662686248272, 0.00019925274757213318, 0.0002045531341203484, 0.00020672636569087706, 0.00020675848356827958, 0.00020475916753233303, 0.00019957181187039023, 0.00019218401931759397, 0.00018333324132564403, 0.0001737603141732121, 0.00016395519170780466, 0.00015470254973254453, 0.0003421247205263725, 1.0], [1.0, 0.0003452738092390988, 0.00015493738331259159, 0.0001638145811514617, 0.0001734920908426273, 0.00018293169566147856, 0.00019161662686248272, 0.00019925274757213318, 0.0002045531341203484, 0.00020672636569087706, 0.00020675848356827958, 0.00020475916753233303, 0.00019957181187039023, 0.00019218401931759397, 0.00018333324132564403, 0.0001737603141732121, 0.00016395519170780466, 0.00015470254973254453, 0.0003421247205263725, 1.0], ], } ratio0_variation_vals = { } ratio_band_edges = { }