|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object peakml.Annotatable peakml.IPeak peakml.Peak peakml.Centroid
public class Centroid
Implementation of a centroid or data-point in a mass spectrometry spectrum or
profile. This class keeps track of a single mass, intensity and optional
scanid value, which makes up a single data-point in a measurement. It's been
chosen to mis-use the centroid value for a data-point as they are essential
the same thing. The actual data associated to a Centroid
instance
is stored in a PeakData
instance.
Nested Class Summary | |
---|---|
static class |
Centroid.Factory
Factory for creating a Centroid instance. |
Nested classes/interfaces inherited from class peakml.IPeak |
---|
IPeak.AnnotationAscending, IPeak.AnnotationDescending, IPeak.MatchCompare<Type>, IPeak.RelationCompare<Type> |
Field Summary | |
---|---|
static PeakData.PeakFactory<Centroid> |
factory
Static instance for the factory, so not everybody will need to produce one |
Constructor Summary | |
---|---|
Centroid(PeakData<Centroid> peakdata,
int index)
Constructs a new Centroid instance linked to the given PeakData
instance. |
Method Summary | |
---|---|
double |
getIntensity()
Retrieves the measured intensity for this peak. |
double |
getMass()
Retrieves the mass of this peak. |
int |
getMeasurementID()
Returns an optional measurement-id for this peak. |
int |
getPatternID()
Returns an optional id for the peak. |
double |
getRetentionTime()
Retrieves the retention time for this peak. |
int |
getScanID()
Retrieves the scan-id for this peak. |
Signal |
getSignal()
Calculates the signal for this IPeak object. |
void |
setIntensity(double intensity)
Sets the intensity of this peak, for more information on mass see IPeak.getIntensity() . |
void |
setMass(double mass)
Sets the mass of this peak, for more information on mass see IPeak.getMass() . |
void |
setMeasurementID(int id)
Sets the profile-id of this peak, for more information on mass see IPeak.getMeasurementID() . |
void |
setPatternID(int id)
Sets the pattern-id of this peak, for more information on mass see IPeak.getPatternID() . |
void |
setRetentionTime(double retentiontime)
Sets the retention time for this peak, for more information on retention time see IPeak.setRetentionTime(double) . |
void |
setScanID(int scan)
Sets the scan-id for this peak, for more information on scan-id see IPeak.getScanID() . |
Methods inherited from class peakml.IPeak |
---|
findRelatedPeaks, getBestPeakOnMass, getBestPeakOnRT, match, match, peaksOfMeasurements, sha1, unpack |
Methods inherited from class peakml.Annotatable |
---|
addAnnotation, addAnnotation, addAnnotation, addAnnotation, addAnnotation, addAnnotations, getAnnotation, getAnnotations, removeAllAnnotations, removeAnnotation |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static PeakData.PeakFactory<Centroid> factory
Constructor Detail |
---|
public Centroid(PeakData<Centroid> peakdata, int index)
Centroid
instance linked to the given PeakData
instance. The given index is used to find the correct data in the collection
of peaks contained in the PeakData
instance.
peakdata
- A PeakData
instance containing all the data.index
- The index indicating the location of the data in the PeakData
instance.Method Detail |
---|
public double getMass()
IPeak
getMass
in class IPeak
public void setMass(double mass)
IPeak
IPeak.getMass()
. It is possible that the class implementing this interface
does not support this method.
setMass
in class IPeak
mass
- The new mass for this peak.public double getIntensity()
IPeak
getIntensity
in class IPeak
public void setIntensity(double intensity)
IPeak
IPeak.getIntensity()
. It is possible that the class implementing this interface
does not support this method.
setIntensity
in class IPeak
intensity
- The new intensity for this peak.public int getScanID()
IPeak
getScanID
in class IPeak
public void setScanID(int scan)
IPeak
IPeak.getScanID()
. It is possible that the class implementing this
interface does not support this method.
setScanID
in class IPeak
scan
- The new scan for this peak.public double getRetentionTime()
IPeak
double rt = peak.getRetentionTime(); int minutes = (int) (rt / 60); int seconds = (int) (rt % 60);
getRetentionTime
in class IPeak
public void setRetentionTime(double retentiontime)
IPeak
IPeak.setRetentionTime(double)
. It is possible that the class
implementing this interface does not support this method.
setRetentionTime
in class IPeak
retentiontime
- The new retention time for this peak.public int getMeasurementID()
IPeak
Header
.
getMeasurementID
in class IPeak
public void setMeasurementID(int id)
IPeak
IPeak.getMeasurementID()
. It is possible that the class implementing this
interface does not support this method.
setMeasurementID
in class IPeak
id
- The new profile-id for this peak.public int getPatternID()
IPeak
getPatternID
in class IPeak
public void setPatternID(int id)
IPeak
IPeak.getPatternID()
. It is possible that the class implementing this
interface does not support this method.
setPatternID
in class IPeak
id
- The new id for this peakspublic Signal getSignal()
IPeak
getSignal
in class IPeak
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |