def cosmol_x(row): key = {'H0': H0, "Om0": Om, 'Ode0': Ol, 'Ok0': Ok} z = row['z'] err = row['dis_Ftab_averr'] model = float(l.lum_dis(z, **key) / u.Mpc) x = ((row['dis_mpc'] - model)**2) / (err**2) return x
def lumdis(z, key): return l.lum_dis(z, **cosmology[key])
def cosmol_x(row, z, err): key = {'H0': H0, "Om0": Om, 'Ode0': Ol, 'Ok0': Ok} z = row[z] model = float(l.lum_dis(z, **key) / u.Mpc) x = ((row['dis_mpc'] - model)**2) / (row[err]**2) return x