Measures the false discovery proportion (FDP) of identifications with an entrapment database.
More...
|
| static Kind | classify (const PeptideHit &hit, const std::string &entrapment_prefix, const std::string &decoy_string="", bool decoy_is_prefix=true) |
| | Classify a peptide hit by its protein accessions.
|
| |
| static double | estimateTERatio (const std::vector< FASTAFile::FASTAEntry > &db, const std::string &entrapment_prefix, const std::string &decoy_string, bool decoy_is_prefix, const std::string &enzyme="Trypsin", Size missed_cleavages=2, Size min_length=7, Size max_length=40) |
| | Estimate T/E, the ratio of distinct searchable target to entrapment peptides, from a database.
|
| |
| static std::unordered_set< std::string > | targetPeptides (const std::vector< FASTAFile::FASTAEntry > &db, const std::string &entrapment_prefix, const std::string &decoy_string, bool decoy_is_prefix, const std::string &enzyme="Trypsin", Size missed_cleavages=2, Size min_length=7, Size max_length=40) |
| | The distinct searchable peptides of the target proteins of a database, with every I replaced by L.
|
| |
| static double | qValue (const PeptideIdentification &pep_id, const PeptideHit &hit) |
| | Return the q-value of a hit.
|
| |
| static PeptidePairs | pairPeptides (const std::vector< FASTAFile::FASTAEntry > &db, const std::string &entrapment_prefix, const std::string &decoy_string, bool decoy_is_prefix, const std::string &enzyme="Trypsin", Size missed_cleavages=2, Size min_length=7, Size max_length=40, Size *mismatched=nullptr) |
| | Pair every entrapment peptide with the target peptide it was made from.
|
| |
| static std::map< std::string, Result > | evaluate (const PeptideIdentificationList &pep_ids, double q_threshold, const std::string &entrapment_prefix, double te_ratio, Level level=Level::PSM, const std::string &class_meta_value="", const std::unordered_set< std::string > *target_peptides=nullptr, const PeptidePairs *pairs=nullptr, const std::string &score_meta_value="", const std::string &decoy_string="", bool decoy_is_prefix=true) |
| | Evaluate the identifications at a q-value threshold.
|
| |
Measures the false discovery proportion (FDP) of identifications with an entrapment database.
An entrapment database adds sequences to the searched targets that cannot be in the sample (for example shuffled copies of the targets, see DecoyDatabase -entrapment_ratio). The entrapment sequences are searched as targets, so the target-decoy FDR does not know about them. A discovery that matches only entrapment sequences is false by construction, which gives estimates of the true FDP among the accepted discoveries that are independent of the decoys. With N_T accepted original-target and N_E accepted entrapment discoveries, N = N_T + N_E, and r the ratio of searchable entrapment to target peptides (T/E = 1/r), following Wen et al., "Assessment of false discovery
rate control in tandem mass spectrometry analysis using entrapment", Nat. Methods (2025):
- lower bound: FDP = N_E / N. A lower bound on the FDP; it can only show that FDR control fails.
- combined: FDP = N_E * (1 + T/E) / N. An estimated upper bound; below the nominal FDR it is evidence of control.
- paired: FDP = (N_E + N_{E>=s>T} + 2 * N_{E>T>=s}) / N, for r = 1 with every entrapment peptide paired to the target peptide it was made from. N_{E>=s>T} counts accepted entrapment peptides whose paired target is not accepted, N_{E>T>=s} those whose paired target is accepted but ranks below or level with them. Also an estimated upper bound, and a tighter one than the combined estimate. As in the paper's FDRBench, it is computed at the peptide level only.
Discoveries are counted at two levels: the top PSM of each spectrum, and peptides (distinct unmodified sequences, I and L taken as one residue). The paper evaluates peptides rather than PSMs. A peptide is accepted at its peptide-level q-value (meta value "peptide q-value", as written by FalseDiscoveryRate -peptide true) when its PSMs carry one; otherwise at the best q-value of its PSMs, which is then not a peptide-level FDR.
A discovery counts as entrapment only when all its proteins are entrapment proteins: a peptide that also occurs in a target protein is a target. Given the target peptides of the database (targetPeptides()), a PSM whose sequence equals a target peptide with I and L taken as one residue also counts as target: I and L have the same mass, so the two cannot be told apart. Decoy PSMs (target_decoy = decoy) are ignored.
Results can be stratified by a meta value of the peptide hits (for example a modification class), which shows whether the nominal FDR holds within each class. A peptide takes the class of its best PSM.