mirror mirrored cells for plot

This commit is contained in:
a.ott 2020-08-01 12:03:08 +02:00
parent b1be741042
commit f973882e62

View File

@ -191,14 +191,14 @@ class ModelFit:
fi_curve = get_fi_curve_class(cell, cell.get_fi_contrasts(), save_dir=cell.get_data_path())
f_inf_slope = fi_curve.get_f_inf_slope()
contrasts = np.array(cell.get_fi_contrasts())
contrasts = np.array(fi_curve.stimulus_values)
if f_inf_slope < 0:
contrasts = contrasts * -1
# print("old contrasts:", cell_data.get_fi_contrasts())
# print("new contrasts:", contrasts)
contrasts = sorted(contrasts)
fi_curve_cell = get_fi_curve_class(cell, contrasts)
print("cell: {} , FI-Curve has saved contrasts that give negative f_inf slope!".format(cell.get_data_path()))
else:
fi_curve_cell = fi_curve
fi_curve_cell = get_fi_curve_class(cell, contrasts, eod_freq=cell.get_eod_frequency(), trials=15)
fi_curve_model = get_fi_curve_class(model, contrasts, eod_freq=cell.get_eod_frequency(), trials=15)
axes[1].set_title("Fi-Curve")