Class SpecificTargetDecoyMap

java.lang.Object
com.compomics.util.experiment.personalization.ExperimentObject
eu.isas.peptideshaker.scoring.maps.SpecificTargetDecoyMap
All Implemented Interfaces:
Serializable
Direct Known Subclasses:
ModificationSpecificMap, SimpleSpecificMap

public abstract class SpecificTargetDecoyMap extends com.compomics.util.experiment.personalization.ExperimentObject implements Serializable
This stores target decoy maps grouped by file and category.
Author:
Marc Vaudel
See Also:
  • Field Details

  • Constructor Details

    • SpecificTargetDecoyMap

      public SpecificTargetDecoyMap()
      Constructor.
  • Method Details

    • estimateProbabilities

      public void estimateProbabilities(com.compomics.util.waiting.WaitingHandler waitingHandler)
      Estimate the posterior error probabilities of the PSMs.
      Parameters:
      waitingHandler - the handler displaying feedback to the user
    • getProbability

      public double getProbability(String file, int category, double score)
      Returns the probability of the given spectrum match at the given score.
      Parameters:
      file - the file scored
      category - the category scored
      score - the corresponding score
      Returns:
      the probability of the given spectrum match at the given score
    • addPoint

      public void addPoint(String fileName, int category, double score, boolean decoy)
      Adds a point representing the corresponding spectrum match at a given score.
      Parameters:
      fileName - the name of the spectrum file
      category - the category of the match
      score - the score
      decoy - whether the match is target or decoy
    • clean

      public abstract void clean(double minimalFDR)
      Handles sparse maps.
      Parameters:
      minimalFDR - the minimal FDR which should be achievable
    • getTargetDecoyMap

      public TargetDecoyMap getTargetDecoyMap(int category, String spectrumFile)
      Returns the desired target decoy map.
      Parameters:
      category - the identified category of the PSM
      spectrumFile - the name of the spectrum file
      Returns:
      the corresponding target decoy map
    • isFileGrouped

      public boolean isFileGrouped(int category, String fileName)
      Indicates whether the given file was grouped for the given category.
      Parameters:
      category - the category of interest
      fileName - the name of the file
      Returns:
      a boolean indicating whether the given file was grouped for the given category
    • getCorrectedCharge

      public int getCorrectedCharge(int category)
      For grouped files, returns the reference category of the group.
      Parameters:
      category - the category of the match
      Returns:
      the category of the group for grouped files, the original category if not found
    • getPossibleCategories

      public Set<Integer> getPossibleCategories()
      Returns the categories found in the map
      Returns:
      the categories found in the map
    • getCategoriesFromGroupedFiles

      public Set<Integer> getCategoriesFromGroupedFiles()
      Returns a list of categories from grouped files.
      Returns:
      a list of categories from grouped files
    • getGroupedCategories

      public int[] getGroupedCategories()
      Returns a list of grouped categories from grouped files.
      Returns:
      a list of grouped categories from grouped files
    • getChargeGroupingMap

      public HashMap<Integer,ArrayList<Integer>> getChargeGroupingMap()
      Returns the map of grouped categories indexed by representative category.
      Returns:
      the map of grouped categories indexed by representative category
    • getFilesAtCategory

      public TreeSet<String> getFilesAtCategory(int category)
      Returns the files at the given category, an empty list if not found.
      Parameters:
      category - the category of interest
      Returns:
      the files at the given category
    • getMapsSize

      public int getMapsSize()
      Returns the overall number of points across all maps.
      Returns:
      the overall number of points across all maps.
    • getTargetDecoyMaps

      public ArrayList<TargetDecoyMap> getTargetDecoyMaps()
      Returns a list of the target decoy maps used for scoring.
      Returns:
      a list of the target decoy maps used for scoring