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

compute FDR also on grouped proteins

parent 5716d087
No related branches found
No related tags found
No related merge requests found
......@@ -24,7 +24,7 @@
<string/>
</property>
<property name="currentIndex">
<number>1</number>
<number>2</number>
</property>
<widget class="QWidget" name="identifications">
<attribute name="title">
......@@ -82,23 +82,16 @@
<item>
<widget class="QGroupBox" name="groupBox_3">
<property name="toolTip">
<string/>
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;FDR is computed using proteins tagged as &amp;quot;decoy&amp;quot; on all valid peptides in valid proteins (check filter parameters)&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="title">
<string>FDR</string>
</property>
<layout class="QFormLayout" name="formLayout">
<item row="0" column="0">
<widget class="QLabel" name="label">
<property name="text">
<string>FDR on peptides</string>
</property>
</widget>
</item>
<layout class="QGridLayout" name="gridLayout_4">
<item row="0" column="1">
<widget class="QLabel" name="peptide_fdr_label">
<property name="toolTip">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;FDR is computed using peptides tagged as &amp;quot;decoy&amp;quot; on all valid peptides in valid proteins (check filter parameters)&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
<string/>
</property>
<property name="text">
<string>0 %</string>
......@@ -112,11 +105,72 @@
</property>
</widget>
</item>
<item row="0" column="2">
<spacer name="horizontalSpacer_3">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item row="0" column="3">
<widget class="QLabel" name="label_6">
<property name="text">
<string>grouped peptides</string>
</property>
</widget>
</item>
<item row="0" column="0">
<widget class="QLabel" name="label">
<property name="text">
<string>FDR on peptides</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QLabel" name="protein_fdr_label">
<property name="toolTip">
<string>FDR is computed using proteins tagged as &quot;decoy&quot; on all valid proteins (check filter parameters)</string>
<string/>
</property>
<property name="text">
<string>0 %</string>
</property>
</widget>
</item>
<item row="0" column="4">
<widget class="QLabel" name="grouped_peptide_fdr_label">
<property name="text">
<string>0 %</string>
</property>
</widget>
</item>
<item row="1" column="2">
<spacer name="horizontalSpacer_4">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item row="1" column="3">
<widget class="QLabel" name="label_7">
<property name="text">
<string>grouped proteins</string>
</property>
</widget>
</item>
<item row="1" column="4">
<widget class="QLabel" name="grouped_protein_fdr_label">
<property name="text">
<string>0 %</string>
</property>
......
......@@ -221,8 +221,25 @@ void ProjectWindow::computeFdr() {
total_peptide += identification_group->countPeptideMassSample(state);
false_peptide += identification_group->countDecoyPeptideMassSample(state);
}
ui->protein_fdr_label->setText(QString("%1 %").arg(QString::number((false_prot/total_prot)*100.0,'f',10)));
ui->peptide_fdr_label->setText(QString("%1 %").arg(QString::number((false_peptide/total_peptide)*100.0,'f',10)));
ui->protein_fdr_label->setText(QString("%1 %").arg(QString::number((false_prot/total_prot)*100.0,'f',2)));
ui->peptide_fdr_label->setText(QString("%1 %").arg(QString::number((false_peptide/total_peptide)*100.0,'f',2)));
state = ValidationState::grouped;
total_prot=0;
false_prot=0;
total_peptide=0;
false_peptide=0;
for (IdentificationGroup * identification_group : _project_sp.get()->getIdentificationGroupList()) {
total_prot += identification_group->countProteinMatch(state);
false_prot += identification_group->countDecoyProteinMatch(state);
//total_peptide += identification_group->countPeptideMatch(state);
//false_peptide += identification_group->countDecoyPeptideMatch(state);
total_peptide += identification_group->countPeptideMassSample(state);
false_peptide += identification_group->countDecoyPeptideMassSample(state);
}
ui->grouped_protein_fdr_label->setText(QString("%1 %").arg(QString::number((false_prot/total_prot)*100.0,'f',2)));
ui->grouped_peptide_fdr_label->setText(QString("%1 %").arg(QString::number((false_peptide/total_peptide)*100.0,'f',2)));
}
catch (pappso::PappsoException exception_pappso) {
QMessageBox::warning(this,
......
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