Skip to content

Commit

Permalink
some issues fixed
Browse files Browse the repository at this point in the history
  • Loading branch information
“Karim committed Jan 22, 2024
1 parent ebf7a8e commit 2008695
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions spectrum_fundamentals/metrics/percolator.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ class Percolator(Metric):
FRAGMENTATION: fragmentation method, e.g. HCD, CID
RETENTION_TIME: observed retention time
PREDICTED_RETENTION_TIME: predicted retention time by Prosit
PROTEINS
"""

metadata: pd.DataFrame
Expand Down Expand Up @@ -272,11 +273,13 @@ def add_percolator_metadata_columns(self):
self.metrics_val["Label"] = self.target_decoy_labels
self.metrics_val["ScanNr"] = self.metadata["SCAN_NUMBER"]
self.metrics_val["filename"] = self.metadata["RAW_FILE"]
# here you should ExpMass
self.metrics_val["ExpMass"] =
self.metrics_val["Peptide"] = self.metadata["MODIFIED_SEQUENCE"].apply(lambda x: "_." + x + "._")

self.metrics_val["Proteins"] = self.metadata[
"MODIFIED_SEQUENCE"
] # we don't need the protein ID to get PSM / peptide results, fill with peptide sequence
"PROTEINS"
] # added proteins column for de-duplication purposes

def apply_lda_and_get_indices_below_fdr(
self, initial_scoring_feature: str = "spectral_angle", fdr_cutoff: float = 0.01
Expand Down

0 comments on commit 2008695

Please sign in to comment.