Class PsProteinSection
java.lang.Object
eu.isas.peptideshaker.export.sections.PsProteinSection
This class outputs the protein related export features.
- Author:
- Marc Vaudel, Harald Barsnes
-
Constructor Summary
ConstructorsConstructorDescriptionPsProteinSection(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.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.biology.genes.GeneMaps geneMaps, com.compomics.util.parameters.identification.IdentificationParameters identificationParameters, int nSurroundingAas, long proteinKey, com.compomics.util.experiment.identification.matches.ProteinMatch proteinMatch, com.compomics.util.experiment.identification.peptide_shaker.PSParameter psParameter, com.compomics.util.io.export.features.peptideshaker.PsProteinFeature tempProteinFeatures, com.compomics.util.waiting.WaitingHandler waitingHandler) Returns the part of the desired section.static StringgetFeature(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.biology.genes.GeneMaps geneMaps, com.compomics.util.parameters.identification.IdentificationParameters identificationParameters, int nSurroundingAas, long proteinKey, com.compomics.util.experiment.identification.matches.ProteinMatch proteinMatch, String fractionName, com.compomics.util.experiment.identification.peptide_shaker.PSParameter psParameter, com.compomics.util.io.export.features.peptideshaker.PsProteinFeature tempProteinFeatures, com.compomics.util.waiting.WaitingHandler waitingHandler) Returns the part of the desired section.voidwriteHeader(ArrayList<String> fractions) Writes the header of the protein 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.experiment.biology.genes.GeneMaps geneMaps, com.compomics.util.parameters.identification.IdentificationParameters identificationParameters, long[] keys, int nSurroundingAa, boolean validatedOnly, boolean decoys, com.compomics.util.waiting.WaitingHandler waitingHandler) Writes the desired section.
-
Constructor Details
-
PsProteinSection
public PsProteinSection(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 section. ProteinFeatures as main features. If Peptide or protein features are selected, they will be added as sub-sections.indexes- 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.experiment.biology.genes.GeneMaps geneMaps, com.compomics.util.parameters.identification.IdentificationParameters identificationParameters, long[] keys, int nSurroundingAa, 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.geneMaps- The gene maps.identificationParameters- The identification parameters.keys- The keys of the PSM matches to output.nSurroundingAa- The number of surrounding amino acids to export.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 whenever an error occurred while writing to the file
-
getFeature
public static String getFeature(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.biology.genes.GeneMaps geneMaps, com.compomics.util.parameters.identification.IdentificationParameters identificationParameters, int nSurroundingAas, long proteinKey, com.compomics.util.experiment.identification.matches.ProteinMatch proteinMatch, com.compomics.util.experiment.identification.peptide_shaker.PSParameter psParameter, com.compomics.util.io.export.features.peptideshaker.PsProteinFeature tempProteinFeatures, com.compomics.util.waiting.WaitingHandler waitingHandler) Returns the part of the desired section.- Parameters:
identificationFeaturesGenerator- the identification features generator of the projectsequenceProvider- the sequence providerproteinDetailsProvider- the protein details providergeneMaps- the gene mapsidentificationParameters- the identification parametersnSurroundingAas- in case a peptide export is included with surrounding amino acids, the number of surrounding amino acids to useproteinKey- the key of the protein match being writtenproteinMatch- the protein match, can be null if not neededpsParameter- the protein match parameter containing the PeptideShaker parameters, can be null if not neededtempProteinFeatures- the protein feature to writewaitingHandler- the waiting handler- Returns:
- the string to write
-
getFeature
public static String getFeature(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.biology.genes.GeneMaps geneMaps, com.compomics.util.parameters.identification.IdentificationParameters identificationParameters, int nSurroundingAas, long proteinKey, com.compomics.util.experiment.identification.matches.ProteinMatch proteinMatch, String fractionName, com.compomics.util.experiment.identification.peptide_shaker.PSParameter psParameter, com.compomics.util.io.export.features.peptideshaker.PsProteinFeature tempProteinFeatures, com.compomics.util.waiting.WaitingHandler waitingHandler) Returns the part of the desired section.- Parameters:
identificationFeaturesGenerator- the identification features generator of the projectsequenceProvider- the sequence providerproteinDetailsProvider- the protein details providergeneMaps- the gene mapsidentificationParameters- the identification parametersnSurroundingAas- in case a peptide export is included with surrounding amino acids, the number of surrounding amino acids to useproteinKey- the key of the protein match being writtenproteinMatch- the protein match, can be null if not neededfractionName- the name of the fractionpsParameter- the protein match parameter containing the PeptideShaker parameters, can be null if not neededtempProteinFeatures- the protein feature to writewaitingHandler- the waiting handler- Returns:
- the string to write
-
writeHeader
Writes the header of the protein section.- Parameters:
fractions- the fraction names- Throws:
IOException- exception thrown whenever an error occurred while writing the file
-