def update(self):
"""
update the table with updated fit parameters
"""
# If the fit is not done, clear the parameters
if not self._fit.fitter.fit_success or len(self._fit.experiments) == 0:
self.clear()
return
# Grab fit results from csv
self._csv_to_table()
self.setRowCount(len(self._data))
self.setColumnCount(len(self._data[0]))
self.setHorizontalHeaderLabels(self._col_name)
# load fit data into the table
for i, row in enumerate(self._data):
for j, col in enumerate(row):
item = QW.QTableWidgetItem(col)
self.setItem(i, j, item)
评论列表
文章目录