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, 1.8850935251798555, 11.698339928057566, 13.344280575539562, 14.65514748201439, 15.751097122302152, 16.698334532374105, 17.50214028776978, 18.24994604316547, 19.8055395683453, 19.810611510791393, 18.251906474820146, 17.496323741007192, 16.684147482014392, 15.752636690647476, 14.652109712230217, 13.353235611510785, 11.70431834532375, 1.8849388489208625, 0.0], '_alpha0.yoda' : [0.0, 1.88547, 11.70757, 13.35556, 14.6497, 15.7534, 16.69368, 17.49936, 18.24403, 19.81111, 19.81224, 18.24121, 17.50132, 16.69187, 15.75187, 14.64482, 13.3505, 11.70297, 1.884462, 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.15933022726015392, 0.988699672860122, 1.127806553340912, 1.2385966057112867, 1.3312220184937755, 1.4112779996728655, 1.4792095585723941, 1.5424125295000826, 1.6738825127614665, 1.6743112854625641, 1.5425799856948899, 1.4787174335130966, 1.4100799717140362, 1.331351650786859, 1.2383415485644875, 1.1285652350105626, 0.9892058534951147, 0.15931696909293933, 0.0], [0.0, 0.15933022726015392, 0.988699672860122, 1.127806553340912, 1.2385966057112867, 1.3312220184937755, 1.4112779996728655, 1.4792095585723941, 1.5424125295000826, 1.6738825127614665, 1.6743112854625641, 1.5425799856948899, 1.4787174335130966, 1.4100799717140362, 1.331351650786859, 1.2383415485644875, 1.1285652350105626, 0.9892058534951147, 0.15931696909293933, 0.0], ], '_alpha0.yoda' : [ [0.0, 0.0009886135, 0.002463486, 0.002631163, 0.002755695, 0.002857616, 0.002941662, 0.003011812, 0.003075227, 0.00320458, 0.003204672, 0.003074989, 0.00301198, 0.002941502, 0.002857477, 0.002755236, 0.002630665, 0.002463002, 0.000988349, 0.0], [0.0, 0.0009886135, 0.002463486, 0.002631163, 0.002755695, 0.002857616, 0.002941662, 0.003011812, 0.003075227, 0.00320458, 0.003204672, 0.003074989, 0.00301198, 0.002941502, 0.002857477, 0.002755236, 0.002630665, 0.002463002, 0.000988349, 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, 1.000199711481216, 1.0007890069872476, 1.0008452628372573, 0.9996282888301823, 1.0001462042726272, 0.9997212576879999, 0.9998411458413619, 0.9996758322927927, 1.0002812562432586, 1.0000822028743392, 0.9994139530117084, 1.0002855605021241, 1.0004628656030483, 0.9999513293766287, 0.9995024803681252, 0.9997951349328079, 0.9998847993292759, 0.9997470215433591, 1.0], } ratio0_yerrs = { 'alpha0.yoda' : [ [1.0, 0.08452112594517151, 0.08451623725592057, 0.0845161001341813, 0.0845161474650024, 0.08451614564733295, 0.08451609332276418, 0.08451592400993622, 0.08451600491595479, 0.08451587531787275, 0.08451588102419352, 0.08451610180136486, 0.08451589347580127, 0.08451615362631568, 0.08451611478967823, 0.08451626235987267, 0.08451623770030046, 0.08451631477456643, 0.08452102792838566, 1.0], [1.0, 0.08452112594517151, 0.08451623725592057, 0.0845161001341813, 0.0845161474650024, 0.08451614564733295, 0.08451609332276418, 0.08451592400993622, 0.08451600491595479, 0.08451587531787275, 0.08451588102419352, 0.08451610180136486, 0.08451589347580127, 0.08451615362631568, 0.08451611478967823, 0.08451626235987267, 0.08451623770030046, 0.08451631477456643, 0.08452102792838566, 1.0], ], '_alpha0.yoda' : [ [1.0, 0.0005244373750133575, 0.0002105842380329126, 0.00019717533553835755, 0.000188035978715461, 0.00018142329882239568, 0.00017616499383796725, 0.00017208249679638362, 0.00016850608723589403, 0.00016180220634442094, 0.00016176542547686253, 0.00016847494831524447, 0.00017214930659637033, 0.00017630520247863764, 0.00018139674367634705, 0.00018804363699926336, 0.00019700581016726077, 0.00021043532201805228, 0.000524340086982575, 1.0], [1.0, 0.0005244373750133575, 0.0002105842380329126, 0.00019717533553835755, 0.000188035978715461, 0.00018142329882239568, 0.00017616499383796725, 0.00017208249679638362, 0.00016850608723589403, 0.00016180220634442094, 0.00016176542547686253, 0.00016847494831524447, 0.00017214930659637033, 0.00017630520247863764, 0.00018139674367634705, 0.00018804363699926336, 0.00019700581016726077, 0.00021043532201805228, 0.000524340086982575, 1.0], ], } ratio0_variation_vals = { } ratio_band_edges = { }