Skip to content
This repository was archived by the owner on Apr 1, 2026. It is now read-only.

Commit 872da74

Browse files
avg lifetime in double exponential assigned to greater of the taus and added to srv calculation
1 parent bda05b2 commit 872da74

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

PythonGUI_apps/Lifetime_analysis/Lifetime_plot_fit.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -432,6 +432,10 @@ def fit_and_plot_with_irf(self):
432432
"\ntau2 = %.5f ns"
433433
"\nnoise = %.5f counts" %(bestfit_params[0], bestfit_params[1], bestfit_params[2], bestfit_params[3], bestfit_params[4]))
434434
#TODO - once tau_avg implemented, set average lifetime spinbox to tau_avg value
435+
if bestfit_params[3] > bestfit_params[1]:
436+
self.ui.average_lifetime_spinBox.setValue(bestfit_params[3])
437+
elif bestfit_params[1] > bestfit_params[3]:
438+
self.ui.average_lifetime_spinBox.setValue(bestfit_params[1])
435439

436440
elif fit_func == "Single Exponential": #single exponential tab
437441
a_bounds = (self.ui.se_a_min_spinBox.value(), self.ui.se_a_max_spinBox.value())

0 commit comments

Comments
 (0)