Class PsPeptideSection
java.lang.Object
eu.isas.peptideshaker.export.sections.PsPeptideSection
This class outputs the peptide related export features.
- Author:
- Marc Vaudel
-
Constructor Summary
ConstructorsConstructorDescriptionPsPeptideSection(ArrayList<com.compomics.util.io.export.ExportFeature> exportFeatures, boolean indexes, boolean header, com.compomics.util.io.export.ExportWriter writer) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionstatic Stringgetfeature(com.compomics.util.experiment.identification.Identification identification, com.compomics.util.experiment.identification.features.IdentificationFeaturesGenerator identificationFeaturesGenerator, com.compomics.util.experiment.io.biology.protein.SequenceProvider sequenceProvider, com.compomics.util.experiment.io.biology.protein.ProteinDetailsProvider proteinDetailsProvider, com.compomics.util.parameters.identification.IdentificationParameters identificationParameters, int nSurroundingAA, String linePrefix, com.compomics.util.experiment.identification.matches.PeptideMatch peptideMatch, com.compomics.util.io.export.features.peptideshaker.PsPeptideFeature peptideFeature, boolean validatedOnly, boolean decoys, com.compomics.util.waiting.WaitingHandler waitingHandler) Returns the component of the section corresponding to the given feature.static StringgetPeptideLocalizationText(String proteinAccession, int[] sites) Returns the peptide localization on the given protein as text in the form accession (site1,site2).static StringgetPeptideModificationLocationConfidence(com.compomics.util.experiment.identification.matches.PeptideMatch peptideMatch, com.compomics.util.parameters.identification.search.ModificationParameters modificationParameters) Returns the peptide modification location confidence as a string.static StringgetProteinGroupText(long proteinGroupKey, com.compomics.util.experiment.identification.Identification identification) Returns a description of the given protein group in the form proteinA,proteinB(confidence).voidWrites the title of the section.voidwriteSection(com.compomics.util.experiment.identification.Identification identification, com.compomics.util.experiment.identification.features.IdentificationFeaturesGenerator identificationFeaturesGenerator, com.compomics.util.experiment.io.biology.protein.SequenceProvider sequenceProvider, com.compomics.util.experiment.io.biology.protein.ProteinDetailsProvider proteinDetailsProvider, com.compomics.util.experiment.mass_spectrometry.SpectrumProvider spectrumProvider, com.compomics.util.parameters.identification.IdentificationParameters identificationParameters, long[] keys, int nSurroundingAA, String linePrefix, boolean validatedOnly, boolean decoys, com.compomics.util.waiting.WaitingHandler waitingHandler) Writes the desired section.
-
Constructor Details
-
PsPeptideSection
public PsPeptideSection(ArrayList<com.compomics.util.io.export.ExportFeature> exportFeatures, boolean indexes, boolean header, com.compomics.util.io.export.ExportWriter writer) Constructor.- Parameters:
exportFeatures- the features to export in this sectionindexes- indicates whether the line index should be writtenheader- indicates whether the table header should be writtenwriter- the writer which will write to the file
-
-
Method Details
-
writeSection
public void writeSection(com.compomics.util.experiment.identification.Identification identification, com.compomics.util.experiment.identification.features.IdentificationFeaturesGenerator identificationFeaturesGenerator, com.compomics.util.experiment.io.biology.protein.SequenceProvider sequenceProvider, com.compomics.util.experiment.io.biology.protein.ProteinDetailsProvider proteinDetailsProvider, com.compomics.util.experiment.mass_spectrometry.SpectrumProvider spectrumProvider, com.compomics.util.parameters.identification.IdentificationParameters identificationParameters, long[] keys, int nSurroundingAA, String linePrefix, boolean validatedOnly, boolean decoys, com.compomics.util.waiting.WaitingHandler waitingHandler) throws IOException Writes the desired section.- Parameters:
identification- The identification of the project.identificationFeaturesGenerator- The identification features generator of the project.sequenceProvider- The sequence provider.proteinDetailsProvider- The protein details provider.spectrumProvider- The spectrum provider.identificationParameters- The identification parameters.keys- The keys of the PSM matches to output.nSurroundingAA- The number of surrounding amino acids to export.linePrefix- The line prefix.validatedOnly- Whether only validated matches should be exported.decoys- Whether decoy matches should be exported as well.waitingHandler- The waiting handler.- Throws:
IOException- exception thrown if an error occurred while reading or writing a file
-
getfeature
public static String getfeature(com.compomics.util.experiment.identification.Identification identification, com.compomics.util.experiment.identification.features.IdentificationFeaturesGenerator identificationFeaturesGenerator, com.compomics.util.experiment.io.biology.protein.SequenceProvider sequenceProvider, com.compomics.util.experiment.io.biology.protein.ProteinDetailsProvider proteinDetailsProvider, com.compomics.util.parameters.identification.IdentificationParameters identificationParameters, int nSurroundingAA, String linePrefix, com.compomics.util.experiment.identification.matches.PeptideMatch peptideMatch, com.compomics.util.io.export.features.peptideshaker.PsPeptideFeature peptideFeature, boolean validatedOnly, boolean decoys, com.compomics.util.waiting.WaitingHandler waitingHandler) Returns the component of the section corresponding to the given feature.- Parameters:
identification- the identification of the projectidentificationFeaturesGenerator- the identification features generator of the projectsequenceProvider- a provider for the protein sequencesproteinDetailsProvider- a provider for protein detailsidentificationParameters- the identification parametersnSurroundingAA- the number of surrounding amino acids to exportlinePrefix- the line prefix to use.peptideMatch- the peptide matchpeptideFeature- the peptide feature to exportvalidatedOnly- whether only validated matches should be exporteddecoys- whether decoy matches should be exported as wellwaitingHandler- the waiting handler- Returns:
- the component of the section corresponding to the given feature
-
getProteinGroupText
public static String getProteinGroupText(long proteinGroupKey, com.compomics.util.experiment.identification.Identification identification) Returns a description of the given protein group in the form proteinA,proteinB(confidence).- Parameters:
proteinGroupKey- the key of the protein groupidentification- the identification object- Returns:
- a description of the given protein group
-
getPeptideLocalizationText
Returns the peptide localization on the given protein as text in the form accession (site1,site2).- Parameters:
proteinAccession- the protein accessionsites- the position of the peptide on the protein- Returns:
- the peptide localization on the given protein as text
-
getPeptideModificationLocationConfidence
public static String getPeptideModificationLocationConfidence(com.compomics.util.experiment.identification.matches.PeptideMatch peptideMatch, com.compomics.util.parameters.identification.search.ModificationParameters modificationParameters) Returns the peptide modification location confidence as a string.- Parameters:
peptideMatch- the peptide matchmodificationParameters- the modification parameters- Returns:
- the peptide modification location confidence as a string
-
writeHeader
Writes the title of the section.- Throws:
IOException- exception thrown whenever an error occurred while writing the file
-