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, 5.834368705035969, 29.303597122302182, 27.069514388489196, 24.654100719424466, 22.48499999999999, 20.697949640287774, 19.338345323741006, 18.480233812949642, 18.253273381294942, 18.12289568345326, 18.139802158273383, 18.8036690647482, 19.96361510791367, 21.562302158273372, 23.54483812949641, 25.787482014388477, 27.895827338129518, 5.552802158273379, 0.0], '_alpha0.yoda' : [0.0, 5.829116, 29.30767, 27.07733, 24.64527, 22.49251, 20.69398, 19.34905, 18.48682, 18.2597, 18.13011, 18.13924, 18.79463, 19.95552, 21.56262, 23.53749, 25.79377, 27.89348, 5.54244, 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.4931152535975467, 2.476621970395388, 2.2878086678293714, 2.0836686064606367, 1.9003422133718397, 1.749309275354582, 1.634401019236902, 1.5618790365907897, 1.5426957368965808, 1.53167763329657, 1.5331045393228455, 1.5892131518803956, 1.6872477488795368, 1.8223605235947755, 1.989918336456746, 2.1794591192974417, 2.3576468193775506, 0.46931894676792246, 0.0], [0.0, 0.4931152535975467, 2.476621970395388, 2.2878086678293714, 2.0836686064606367, 1.9003422133718397, 1.749309275354582, 1.634401019236902, 1.5618790365907897, 1.5426957368965808, 1.53167763329657, 1.5331045393228455, 1.5892131518803956, 1.6872477488795368, 1.8223605235947755, 1.989918336456746, 2.1794591192974417, 2.3576468193775506, 0.46931894676792246, 0.0], ], '_alpha0.yoda' : [ [0.0, 0.002064213, 0.004628537, 0.004448935, 0.004244436, 0.004054827, 0.003889335, 0.003760825, 0.003676075, 0.003653423, 0.003640435, 0.003641352, 0.003706553, 0.00381931, 0.003970125, 0.004147948, 0.004342207, 0.004515485, 0.002012814, 0.0], [0.0, 0.002064213, 0.004628537, 0.004448935, 0.004244436, 0.004054827, 0.003889335, 0.003760825, 0.003676075, 0.003653423, 0.003640435, 0.003641352, 0.003706553, 0.00381931, 0.003970125, 0.004147948, 0.004342207, 0.004515485, 0.002012814, 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.999099696076555, 1.000138989001276, 1.0002887237428288, 0.9996418153910798, 1.0003340004447414, 0.9998082109408534, 1.0005535466494049, 1.0003563908940234, 1.0003520803403756, 1.0003980774746346, 0.9999690096800132, 0.9995192924999332, 0.9995945069132062, 1.0000147406211217, 0.9996879091095893, 1.0002438386814196, 0.9999158534320899, 0.9981338866435319, 1.0], } ratio0_yerrs = { 'alpha0.yoda' : [ [1.0, 0.08451904199539385, 0.08451597119831057, 0.08451605872923303, 0.08451610667830835, 0.08451599792625486, 0.0845160658787969, 0.08451607373203773, 0.08451619456764314, 0.08451611416051323, 0.08451616452745114, 0.08451605623623694, 0.08451612004062234, 0.0845161429810728, 0.08451604611688195, 0.08451611879904258, 0.08451616633533211, 0.08451611026983208, 0.0845192991557717, 1.0], [1.0, 0.08451904199539385, 0.08451597119831057, 0.08451605872923303, 0.08451610667830835, 0.08451599792625486, 0.0845160658787969, 0.08451607373203773, 0.08451619456764314, 0.08451611416051323, 0.08451616452745114, 0.08451605623623694, 0.08451612004062234, 0.0845161429810728, 0.08451604611688195, 0.08451611879904258, 0.08451616633533211, 0.08451611026983208, 0.0845192991557717, 1.0], ], '_alpha0.yoda' : [ [1.0, 0.0003538022885352211, 0.0001579511546204457, 0.00016435222797686486, 0.00017215943296020912, 0.00018033475650433635, 0.00018790919233997733, 0.00019447501515980106, 0.0001989192905894982, 0.00020015166176954585, 0.00020087490782854444, 0.00020073824224919762, 0.00019711860420628153, 0.00019131354613654154, 0.00018412342851232506, 0.00017617228783592913, 0.00016838429582140691, 0.0001618695493511315, 0.0003624861723195044, 1.0], [1.0, 0.0003538022885352211, 0.0001579511546204457, 0.00016435222797686486, 0.00017215943296020912, 0.00018033475650433635, 0.00018790919233997733, 0.00019447501515980106, 0.0001989192905894982, 0.00020015166176954585, 0.00020087490782854444, 0.00020073824224919762, 0.00019711860420628153, 0.00019131354613654154, 0.00018412342851232506, 0.00017617228783592913, 0.00016838429582140691, 0.0001618695493511315, 0.0003624861723195044, 1.0], ], } ratio0_variation_vals = { } ratio_band_edges = { }