import numpy as np from numpy import nan add_legend_handle = [ 'alpha1.yoda', '_alpha1.yoda' ] xpoints = { 'alpha1.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], '_alpha1.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 = { 'alpha1.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], '_alpha1.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['alpha1.yoda'][i] - xedges['alpha1.yoda'][i]) for i in range(len(xpoints['alpha1.yoda']))], [abs(xedges['alpha1.yoda'][i+1] - xpoints['alpha1.yoda'][i]) for i in range(len(xpoints['alpha1.yoda']))] ] yvals = { 'alpha1.yoda' : [0.0, 2.9516582733812937, 16.89498741007196, 19.069154676258986, 20.799532374100725, 22.21999999999999, 23.404784172661873, 24.334730215827335, 25.05874100719425, 25.660053956834503, 25.667787769784205, 25.047859712230217, 24.343723021582733, 23.40330935251799, 22.218705035971215, 20.804118705035975, 19.073309352517978, 16.900838129496417, 2.9497068345323725, 0.0], '_alpha1.yoda' : [0.0, 2.95507, 16.89542, 19.07392, 20.79212, 22.22534, 23.41108, 24.33626, 25.05015, 25.65875, 25.65955, 25.05036, 24.3441, 23.40056, 22.2255, 20.80079, 19.07658, 16.90217, 2.952937, 0.0], } xerrs = { 'alpha1.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], ], '_alpha1.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 = { 'alpha1.yoda' : [ [0.0, 0.24947398208984634, 1.4278976225614146, 1.6116518999757061, 1.7578945682194709, 1.8779476252725764, 1.9780853220546608, 2.056672567421308, 2.117863606413266, 2.1686859136826064, 2.1693391381858667, 2.116946968800305, 2.0574336824030737, 1.9779569444860183, 1.8778399640251928, 1.7582819730094228, 1.6120027110837554, 1.4283933289537873, 0.2493106795073411, 0.0], [0.0, 0.24947398208984634, 1.4278976225614146, 1.6116518999757061, 1.7578945682194709, 1.8779476252725764, 1.9780853220546608, 2.056672567421308, 2.117863606413266, 2.1686859136826064, 2.1693391381858667, 2.116946968800305, 2.0574336824030737, 1.9779569444860183, 1.8778399640251928, 1.7582819730094228, 1.6120027110837554, 1.4283933289537873, 0.2493106795073411, 0.0], ], '_alpha1.yoda' : [ [0.0, 0.001460288, 0.003491718, 0.003710007, 0.003873504, 0.004004782, 0.004110224, 0.004190652, 0.004251673, 0.004303011, 0.004303078, 0.00425169, 0.004191327, 0.0041093, 0.004004797, 0.003874312, 0.003710265, 0.003492416, 0.001459761, 0.0], [0.0, 0.001460288, 0.003491718, 0.003710007, 0.003873504, 0.004004782, 0.004110224, 0.004190652, 0.004251673, 0.004303011, 0.004303078, 0.00425169, 0.004191327, 0.0041093, 0.004004797, 0.003874312, 0.003710265, 0.003492416, 0.001459761, 0.0], ], } variation_yvals = { } # lists for ratio plot ratio0_yvals = { 'alpha1.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], '_alpha1.yoda' : [1.0, 1.0011558677538908, 1.0000256046315716, 1.000249896957779, 0.9996436278485783, 1.0002403240324036, 1.0002689974533274, 1.0000628642339198, 0.9996571652505692, 0.9999491833946766, 0.9996790619488485, 1.0000998204157365, 1.0000154856517607, 0.9998825229168842, 1.0003058217847434, 0.9998399977868243, 1.0001714777137818, 1.000078804997325, 1.0010950801719722, 1.0], } ratio0_yerrs = { 'alpha1.yoda' : [ [1.0, 0.08451994065155097, 0.08451605129401708, 0.084516169035128, 0.08451606202495089, 0.08451609474674064, 0.08451628126377587, 0.08451593870901622, 0.08451596214691062, 0.08451603092225694, 0.08451601507861871, 0.08451608213721569, 0.08451598305563154, 0.08451612183100111, 0.08451617504193171, 0.08451605174622476, 0.08451615193201623, 0.08451612387558842, 0.08452049423646035, 1.0], [1.0, 0.08451994065155097, 0.08451605129401708, 0.084516169035128, 0.08451606202495089, 0.08451609474674064, 0.08451628126377587, 0.08451593870901622, 0.08451596214691062, 0.08451603092225694, 0.08451601507861871, 0.08451608213721569, 0.08451598305563154, 0.08451612183100111, 0.08451617504193171, 0.08451605174622476, 0.08451615193201623, 0.08451612387558842, 0.08452049423646035, 1.0], ], '_alpha1.yoda' : [ [1.0, 0.0004947347777922667, 0.00020667183202033106, 0.0001945553991766055, 0.00018623034067935252, 0.00018023321332133222, 0.0001756146935463296, 0.00017220868950806756, 0.00016966826061929306, 0.00016769298331322882, 0.00016764506698413367, 0.00016974264663116147, 0.0001721728018464571, 0.00017558627876522408, 0.00018024439288952214, 0.00018622812410035709, 0.0001945265465696537, 0.0002066415862480106, 0.0004948834178741092, 1.0], [1.0, 0.0004947347777922667, 0.00020667183202033106, 0.0001945553991766055, 0.00018623034067935252, 0.00018023321332133222, 0.0001756146935463296, 0.00017220868950806756, 0.00016966826061929306, 0.00016769298331322882, 0.00016764506698413367, 0.00016974264663116147, 0.0001721728018464571, 0.00017558627876522408, 0.00018024439288952214, 0.00018622812410035709, 0.0001945265465696537, 0.0002066415862480106, 0.0004948834178741092, 1.0], ], } ratio0_variation_vals = { } ratio_band_edges = { }