AFLPcore
Class TracePeakFinder
java.lang.Object
|
+--AFLPcore.TracePeakFinder
- public class TracePeakFinder
- extends java.lang.Object
This is a simple algorithm that is used to find peaks in a set of trace data.
There is a separate file, PeakLocate.java, that was created with this purpose
in mind, but that wouldn't have done exactly what I wanted.
The algorithm has three steps.
1) Find a point that is high than the points on either side of it and check
if it's above the minimum threshold.
2) Check the points thirty samples on either side of it to make sure there's
not a nearby point that's even higher.
3) Make sure it meets the minimum width requirement.
It's pretty simple, and fairly effective. The peaks on molecular weight
standards tend to be very well defined.
Method Summary |
static double |
find(double[] trace)
|
static double |
find(double[] trace,
int offset)
|
static double |
find(double[] trace,
int offset,
double minPeakValue)
|
static long |
find(double[] trace,
int offset,
double minPeakValue,
double minPeakWidth)
This is the one method in this class, really. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
TracePeakFinder
public TracePeakFinder()
find
public static double find(double[] trace)
find
public static double find(double[] trace,
int offset)
find
public static double find(double[] trace,
int offset,
double minPeakValue)
find
public static long find(double[] trace,
int offset,
double minPeakValue,
double minPeakWidth)
- This is the one method in this class, really. Quite simple, it searches
through the data until it finds a peak, then returns the index of that number.
parameters: