public class MSnSpectrum extends Spectrum
fileName, level, peakList, scanNumber, scanStartTime, SPECTRUM_KEY_SPLITTER, spectrumTitle
Constructor and Description |
---|
MSnSpectrum()
Constructor for the spectrum.
|
MSnSpectrum(int level,
Precursor precursor,
java.lang.String spectrumTitle,
java.util.HashMap<java.lang.Double,Peak> peakMap,
java.lang.String fileName)
Constructor for the spectrum.
|
MSnSpectrum(int level,
Precursor precursor,
java.lang.String spectrumTitle,
java.util.HashMap<java.lang.Double,Peak> peakMap,
java.lang.String fileName,
double scanStartTime)
Constructor for the spectrum.
|
MSnSpectrum(int level,
Precursor precursor,
java.lang.String spectrumTitle,
java.lang.String fileName)
Minimal constructor for the spectrum.
|
Modifier and Type | Method and Description |
---|---|
java.lang.String |
asMgf()
Returns the peak list as an mgf bloc.
|
java.lang.String |
asMgf(java.util.HashMap<java.lang.String,java.lang.String> additionalTags)
Returns the peak list as an mgf bloc.
|
Precursor |
getPrecursor()
Returns the precursor.
|
void |
setPrecursor(Precursor precursor)
Set the precursor.
|
void |
writeMgf(java.io.BufferedWriter writer1)
Writes the spectrum in the mgf format using the given writer.
|
void |
writeMgf(java.io.BufferedWriter mgfWriter,
java.util.HashMap<java.lang.String,java.lang.String> additionalTags)
Writes the spectrum in the mgf format using the given writer.
|
addPeak, getDesignaledPeakList, getFileName, getIntensityLimit, getIntensityValuesAsArray, getJFreePeakList, getLevel, getMaxIntensity, getMaxMz, getMinMz, getMzAndIntensityAsArray, getMzValuesAsArray, getPeakList, getPeakMap, getPeaksAboveIntensityThreshold, getRecalibratedPeakList, getScanNumber, getScanStartTime, getSpectrumFile, getSpectrumKey, getSpectrumKey, getSpectrumTitle, getSpectrumTitle, getSubSpectrum, getTotalIntensity, removePeakList, setPeakList, setPeaks, setScanNumber, setScanStartTime, setSpectrumTitle
addUrParam, getParameterKey, getUrParam
public MSnSpectrum()
public MSnSpectrum(int level, Precursor precursor, java.lang.String spectrumTitle, java.lang.String fileName)
level
- MS levelprecursor
- precursorspectrumTitle
- spectrum titlefileName
- file namepublic MSnSpectrum(int level, Precursor precursor, java.lang.String spectrumTitle, java.util.HashMap<java.lang.Double,Peak> peakMap, java.lang.String fileName)
level
- MS levelprecursor
- precursorspectrumTitle
- spectrum titlepeakMap
- set of peaksfileName
- file namepublic MSnSpectrum(int level, Precursor precursor, java.lang.String spectrumTitle, java.util.HashMap<java.lang.Double,Peak> peakMap, java.lang.String fileName, double scanStartTime)
level
- MS levelprecursor
- precursorspectrumTitle
- spectrum titlepeakMap
- set of peaksfileName
- file namescanStartTime
- The time point when the spectrum was recordedpublic Precursor getPrecursor()
public void setPrecursor(Precursor precursor)
precursor
- the precursor to setpublic java.lang.String asMgf()
public java.lang.String asMgf(java.util.HashMap<java.lang.String,java.lang.String> additionalTags)
additionalTags
- additional tags which will be added after the BEGIN
IONS tag in alphabetic orderpublic void writeMgf(java.io.BufferedWriter writer1) throws java.io.IOException
writer1
- a buffered writer where the spectrum will be writtenjava.io.IOException
public void writeMgf(java.io.BufferedWriter mgfWriter, java.util.HashMap<java.lang.String,java.lang.String> additionalTags) throws java.io.IOException
mgfWriter
- a buffered writer where the spectrum will be writtenadditionalTags
- additional tags which will be added after the BEGIN
IONS tag in alphabetic orderjava.io.IOException
Copyright © 2013. All Rights Reserved.