Skip to content
Snippets Groups Projects
Commit 991bfff5 authored by Olivier Langella's avatar Olivier Langella
Browse files

new columns in peptide list : MH+ delta mass

parent 7301303c
No related branches found
No related tags found
No related merge requests found
......@@ -51,7 +51,9 @@ void PeptideMatch::setExperimentalMass(pappso::pappso_double exp_mass) {
void PeptideMatch::setStart(unsigned int start) {
_start =start;
}
pappso::mz PeptideMatch::getDeltaMhplus() const {
return (_peptide_sp.get()->getMass() - _exp_mass);
}
unsigned int PeptideMatch::getStart() const {
return _start;
}
......
......@@ -70,6 +70,10 @@ public :
/** @brief validate or invalidate peptides and proteins based automatic filters and manual checks
* */
void updateAutomaticFilters(const AutomaticFilterParameters & automatic_filter_parameters);
/** @brief get delta between theoretical mass and experimental mass (z=1)
*/
pappso::mz getDeltaMhplus() const;
private :
pappso::MsRunIdSp _msrunid_sp;
......
......@@ -75,6 +75,7 @@ void PeptideListWindow::setProteinMatch(Project * p_project, ProteinMatch * p_pr
_p_protein_match = p_protein_match;
_peptide_table_model_p->setProteinMatch(p_project, p_protein_match);
_p_proxy_model->setSourceModel(_peptide_table_model_p);
ui->proteinLabel->setText(p_protein_match->getProteinXtpSp().get()->getDescription());
}
}
......
......@@ -98,7 +98,7 @@ int PeptideTableModel::rowCount(const QModelIndex &parent ) const {
return 0;
}
int PeptideTableModel::columnCount(const QModelIndex &parent ) const {
return 13;
return 15;
}
QVariant PeptideTableModel::headerData(int section, Qt::Orientation orientation, int role) const
{
......@@ -133,6 +133,10 @@ QVariant PeptideTableModel::headerData(int section, Qt::Orientation orientation,
return QString("subgroups");
case 12:
return QString("Evalue");
case 13:
return QString("theoretical MH+");
case 14:
return QString("delta MH+");
}
}
}
......@@ -200,7 +204,8 @@ QVariant PeptideTableModel::data(const QModelIndex &index, int role ) const {
}
if (col ==9) {
return QVariant((qreal) _p_protein_match->getPeptideMatchList().at(row)->getPeptideXtpSp().get()->size());
}if (col ==10) {
}
if (col ==10) {
GroupingGroup * p_grp = _p_protein_match->getGroupingGroupSp().get();
if (p_grp != nullptr) return QVariant((qreal) p_grp->countSubgroupPresence(_p_protein_match->getPeptideMatchList().at(row)));
return QVariant();
......@@ -214,6 +219,14 @@ QVariant PeptideTableModel::data(const QModelIndex &index, int role ) const {
return QVariant((qreal) _p_protein_match->getPeptideMatchList().at(row)->getEvalue());
}
if (col ==13) {
return QVariant((qreal) _p_protein_match->getPeptideMatchList().at(row)->getPeptideXtpSp().get()->getMz(1));
}
if (col ==14) {
return QVariant((qreal) _p_protein_match->getPeptideMatchList().at(row)->getDeltaMhplus());
}
}
return QString("Row%1, Column%2")
.arg(index.row() + 1)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment