109 Eigen::VectorXf col_cals(this->
data->ncol);
110 Eigen::VectorXf row_cals(this->
data->nrow);
117 for (j = 0; j < this->
data->nrow; j++) {
118 name = this->
data->rowlist[j];
120 for (p = 0; p < nch; p++)
121 if (QString::compare(name,chs[p].ch_name) == 0) {
122 row_cals[j] = chs[p].range*chs[p].cal;
127 qCritical(
"Channel %s not found. Cannot calibrate the compensation matrix.",name.toUtf8().constData());
131 for (k = 0; k < this->
data->ncol; k++) {
132 name = this->
data->collist[k];
134 for (p = 0; p < nch; p++)
135 if (QString::compare(name,chs[p].ch_name) == 0) {
136 col_cals[k] = chs[p].range*chs[p].cal;
141 qCritical(
"Channel %s not found. Cannot calibrate the compensation matrix.",name.toUtf8().constData());
146 for (j = 0; j < this->
data->nrow; j++)
147 for (k = 0; k < this->
data->ncol; k++)
148 this->
data->data(j, k) = row_cals[j]*this->
data->data(j, k)/col_cals[k];
151 for (j = 0; j < this->
data->nrow; j++)
152 for (k = 0; k < this->
data->ncol; k++)
153 this->
data->data(j, k) = col_cals[k]*this->
data->data(j, k)/row_cals[j];