Class ModificationScoring
java.lang.Object
com.compomics.util.experiment.personalization.ExperimentObject
com.compomics.util.experiment.identification.peptide_shaker.ModificationScoring
- All Implemented Interfaces:
Serializable
This class contains stores the modification localization scores.
- Author:
- Marc Vaudel
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intIndex for a confident assignment.static final intIndex for a doubtful assignment.static final intIndex indicating that the modification was not found.static final intIndex for a random location choice.static final StringThe separator used to separate locations in the modification location key.static final intIndex for a very confident assignment.Fields inherited from class com.compomics.util.experiment.personalization.ExperimentObject
NO_KEY -
Constructor Summary
ConstructorsConstructorDescriptionDefault constructor Constructor.ModificationScoring(String ptmName) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionvoidaddAll(ModificationScoring anotherScore) Adds all scores from another score if better.Returns the sites of all localized PTMs.static StringgetConfidenceLevel(int index) Convenience method returning the given confidence level as a string.Returns the confidently and very confidently localized PTMs.doublegetDeltaScore(int site) Returns the delta score at a given site.Returns a set of sites where a D-score is availableintgetLocalizationConfidence(int site) Returns the confidence of the PTM localization.intReturns the minimal confidence among the PTM sites of this scoring.getName()Returns the name of the inspected protein.Returns an ordered list of sites where the D-score was used.Returns an ordered list of sites where the probabilistic score was used.Returns sites of all localized PTMs ordered increasingly.static String[]Convenience method returning all confidence levels as string.doublegetProbabilisticScore(int site) Returns the probabilistic score at a given site.Returns a set of sites where a probabilistic score is availableReturns the map of the localization.getPtmLocations(int confidenceLevel) Returns the PTM locations at a given confidence level (see static fields).Returns a set of sites where a score is available.Returns the not found, randomly or doubtfully localized PTMs.voidsetDeltaScore(int site, double score) Sets the delta score at a given site.voidsetProbabilisticScore(int site, double score) Sets the probabilistic score at a given site.voidsetSiteConfidence(int site, int confidenceLevel) Sets the confidence level of a modification site.Methods inherited from class com.compomics.util.experiment.personalization.ExperimentObject
addUrParam, asLong, clearParametersMap, getId, getUrParam, getUrParams, removeUrParam, setId, setUrParams
-
Field Details
-
NOT_FOUND
public static final int NOT_FOUNDIndex indicating that the modification was not found.- See Also:
-
RANDOM
public static final int RANDOMIndex for a random location choice.- See Also:
-
DOUBTFUL
public static final int DOUBTFULIndex for a doubtful assignment.- See Also:
-
CONFIDENT
public static final int CONFIDENTIndex for a confident assignment.- See Also:
-
VERY_CONFIDENT
public static final int VERY_CONFIDENTIndex for a very confident assignment.- See Also:
-
SEPARATOR
The separator used to separate locations in the modification location key.- See Also:
-
-
Constructor Details
-
ModificationScoring
public ModificationScoring()Default constructor Constructor. -
ModificationScoring
Constructor.- Parameters:
ptmName- the name of the PTM of interest.
-
-
Method Details
-
getName
Returns the name of the inspected protein.- Returns:
- the name of the inspected protein
-
getScoredSites
Returns a set of sites where a score is available.- Returns:
- a set of sites where a score is available
-
setDeltaScore
public void setDeltaScore(int site, double score) Sets the delta score at a given site. First amino acid is 1.- Parameters:
site- the modification sitescore- the delta score
-
getDeltaScore
public double getDeltaScore(int site) Returns the delta score at a given site. First amino acid is 1.- Parameters:
site- the site of interest- Returns:
- the attached delta score. 0 if not found.
-
setProbabilisticScore
public void setProbabilisticScore(int site, double score) Sets the probabilistic score at a given site. First amino acid is 1.- Parameters:
site- the modification sitescore- the delta score
-
getProbabilisticScore
public double getProbabilisticScore(int site) Returns the probabilistic score at a given site. First amino acid is 1.- Parameters:
site- the site of interest- Returns:
- the attached probabilistic score. 0 if not found.
-
getProbabilisticSites
Returns a set of sites where a probabilistic score is available- Returns:
- a set of sites where a probabilistic score is available
-
getOrderedProbabilisticSites
Returns an ordered list of sites where the probabilistic score was used. Sites are ordered by decreasing score. In order to reduce systematic error, if sites score equally their order is random.- Returns:
- a list of sites where the probabilistic score was used
-
getDSites
Returns a set of sites where a D-score is available- Returns:
- a set of sites where a D-score is available
-
getOrderedDSites
Returns an ordered list of sites where the D-score was used. Sites are ordered by decreasing score. In order to reduce systematic error, if sites score equally their order is random.- Returns:
- a list of sites where the D-score was used
-
addAll
Adds all scores from another score if better.- Parameters:
anotherScore- another score
-
setSiteConfidence
public void setSiteConfidence(int site, int confidenceLevel) Sets the confidence level of a modification site. 1 is the first amino acid.- Parameters:
site- the modification siteconfidenceLevel- the confidence level
-
getPtmLocationAtAA
Returns the map of the localization. site > confidence level.- Returns:
- the map of the localization
-
getAllPtmLocations
Returns the sites of all localized PTMs.- Returns:
- the sites of all localized PTMs
-
getOrderedPtmLocations
Returns sites of all localized PTMs ordered increasingly.- Returns:
- sites of all localized PTMs ordered increasingly
-
getLocalizationConfidence
public int getLocalizationConfidence(int site) Returns the confidence of the PTM localization.- Parameters:
site- the modification site- Returns:
- the confidence of the localization as indexed by the static fields
-
getMinimalLocalizationConfidence
public int getMinimalLocalizationConfidence()Returns the minimal confidence among the PTM sites of this scoring.- Returns:
- the minimal confidence among the PTM sites of this scoring
-
getConfidentPtmLocations
Returns the confidently and very confidently localized PTMs.- Returns:
- the confidently and very confidently localized PTMs
-
getSecondaryPtmLocations
Returns the not found, randomly or doubtfully localized PTMs.- Returns:
- the not found, randomly or doubtfully localized PTMs
-
getPtmLocations
Returns the PTM locations at a given confidence level (see static fields).- Parameters:
confidenceLevel- the confidence level- Returns:
- the PTM locations at the given confidence level
-
getPossibleConfidenceLevels
Convenience method returning all confidence levels as string.- Returns:
- an array with all confidence levels as string
-
getConfidenceLevel
Convenience method returning the given confidence level as a string.- Parameters:
index- the confidence level- Returns:
- the corresponding string
-