public class PeptideUtils extends Object
Constructor and Description |
---|
PeptideUtils() |
Modifier and Type | Method and Description |
---|---|
static TreeMap<String,String[]> |
getAaAfter(Peptide peptide,
int nAa,
SequenceProvider sequenceProvider)
Returns the amino acids before the given peptide as a string in a map
based on the peptide protein mapping.
|
static String |
getAaAfter(Peptide peptide,
String accession,
int index,
int nAa,
SequenceProvider sequenceProvider)
Returns the amino acids before the given peptide as a string.
|
static TreeMap<String,String[]> |
getAaBefore(Peptide peptide,
int nAa,
SequenceProvider sequenceProvider)
Returns the amino acids before the given peptide as a string in a map
based on the peptide protein mapping.
|
static String |
getAaBefore(Peptide peptide,
String accession,
int index,
int nAa,
SequenceProvider sequenceProvider)
Returns the amino acids before the given peptide as a string in a map
based on the peptide protein mapping.
|
static int |
getNEnzymaticTermini(int peptideStart,
int peptideEnd,
String proteinSequence,
Enzyme enzyme)
Returns the number of enzymatic termini for the given enzyme on this
protein at the given location.
|
static String |
getPeptideModificationsAsString(Peptide peptide,
boolean variable)
Returns the peptide modifications as a string.
|
static String |
getTaggedModifiedSequence(Peptide peptide,
ModificationParameters modificationProfile,
HashMap<Integer,ArrayList<String>> confidentModificationSites,
HashMap<Integer,ArrayList<String>> representativeAmbiguousModificationSites,
HashMap<Integer,ArrayList<String>> secondaryAmbiguousModificationSites,
HashMap<Integer,ArrayList<String>> fixedModificationSites,
boolean useHtmlColorCoding,
boolean includeHtmlStartEndTags,
boolean useShortName)
Returns the modified sequence as an tagged string with potential
modification sites color coded or with Modification tags, e.g,
<mox>.
|
static boolean |
isDecoy(Peptide peptide,
SequenceProvider sequenceProvider)
Returns a boolean indicating whether the peptide matches a decoy
sequence.
|
static boolean |
isEnzymatic(Peptide peptide,
SequenceProvider sequenceProvider,
ArrayList<Enzyme> enzymes)
Returns a boolean indicating whether the peptide is enzymatic in at least one protein using one of the given enzymes.
|
static boolean |
isEnzymatic(Peptide peptide,
String proteinAccession,
String proteinSequence,
ArrayList<Enzyme> enzymes)
Returns a boolean indicating whether the peptide is enzymatic using one of the given enzymes.
|
static boolean |
isVariant(Peptide peptide,
String accession)
Returns a boolean indicating whether the peptide needs variants to be mapped to the given protein.
|
public static boolean isDecoy(Peptide peptide, SequenceProvider sequenceProvider)
peptide
- the peptidesequenceProvider
- a sequence provider.public static String getAaBefore(Peptide peptide, String accession, int index, int nAa, SequenceProvider sequenceProvider)
peptide
- the peptideaccession
- the accession of the proteinindex
- the position of the peptide on the protein sequencenAa
- the number of amino acids to includesequenceProvider
- the sequence providerpublic static TreeMap<String,String[]> getAaBefore(Peptide peptide, int nAa, SequenceProvider sequenceProvider)
peptide
- the peptidenAa
- the number of amino acids to includesequenceProvider
- the sequence providerpublic static String getAaAfter(Peptide peptide, String accession, int index, int nAa, SequenceProvider sequenceProvider)
peptide
- the peptideaccession
- the accession of the proteinindex
- the position of the peptide on the protein sequencenAa
- the number of amino acids to includesequenceProvider
- the sequence providerpublic static TreeMap<String,String[]> getAaAfter(Peptide peptide, int nAa, SequenceProvider sequenceProvider)
peptide
- the peptidenAa
- the number of amino acids to includesequenceProvider
- the sequence providerpublic static String getPeptideModificationsAsString(Peptide peptide, boolean variable)
peptide
- the peptidevariable
- if true, only variable Modifications are shown, false
return only the fixed Modificationspublic static String getTaggedModifiedSequence(Peptide peptide, ModificationParameters modificationProfile, HashMap<Integer,ArrayList<String>> confidentModificationSites, HashMap<Integer,ArrayList<String>> representativeAmbiguousModificationSites, HashMap<Integer,ArrayList<String>> secondaryAmbiguousModificationSites, HashMap<Integer,ArrayList<String>> fixedModificationSites, boolean useHtmlColorCoding, boolean includeHtmlStartEndTags, boolean useShortName)
modificationProfile
- the modification profile of the searchincludeHtmlStartEndTags
- if true, start and end HTML tags are addedpeptide
- the peptide to annotateconfidentModificationSites
- the confidently localized variable
modification sites in a map: aa number > list of modifications (1 is
the first AA) (can be null)representativeAmbiguousModificationSites
- the representative site
of the ambiguously localized variable modifications in a map: aa number
> list of modifications (1 is the first AA) (can be null)secondaryAmbiguousModificationSites
- the secondary sites of the
ambiguously localized variable modifications in a map: aa number >
list of modifications (1 is the first AA) (can be null)fixedModificationSites
- the fixed modification sites in a map: aa
number > list of modifications (1 is the first AA) (can be null)useHtmlColorCoding
- if true, color coded HTML is used, otherwise
Modification tags, e.g, <mox>, are useduseShortName
- if true the short names are used in the tagspublic static int getNEnzymaticTermini(int peptideStart, int peptideEnd, String proteinSequence, Enzyme enzyme)
peptideStart
- the 0 based index of the peptide start on the proteinpeptideEnd
- the 0 based index of the peptide end on the proteinproteinSequence
- the protein sequenceenzyme
- the enzyme to usepublic static boolean isEnzymatic(Peptide peptide, String proteinAccession, String proteinSequence, ArrayList<Enzyme> enzymes)
peptide
- the peptideproteinAccession
- the accession of the proteinproteinSequence
- the sequence of the proteinenzymes
- the enzymes used for digestionpublic static boolean isEnzymatic(Peptide peptide, SequenceProvider sequenceProvider, ArrayList<Enzyme> enzymes)
peptide
- the peptidesequenceProvider
- the sequence providerenzymes
- the enzymes used for digestionpublic static boolean isVariant(Peptide peptide, String accession)
peptide
- the peptideaccession
- the accession of the proteinCopyright © 2018. All rights reserved.