Class FittingUtils
java.lang.Object
org.dawnsci.plotting.tools.fitting.FittingUtils
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic FittedFunctionsThis method runs a fit on data passed in.static FittedFunctionsstatic List<IdentifiedPeak> getIdentifiedPeaks(FittedFunctions fittedPeaks, org.eclipse.january.dataset.Dataset x, org.eclipse.core.runtime.IProgressMonitor monitor) static AddgetInitialPeaks(org.eclipse.january.dataset.Dataset xDataSet, org.eclipse.january.dataset.Dataset yDataSet, Integer nPeaks, Class<? extends IPeak> peakClass) static IOptimizerstatic intstatic intstatic javax.vecmath.Vector3dgetQ(FittedPeaksInfo info, FittedFunction p) static AddgetSeededPeakFit(List<IdentifiedPeak> foundPeaks, org.eclipse.january.dataset.Dataset xDataSet, org.eclipse.january.dataset.Dataset yDataSet, Class<? extends IPeak> peakClass) A variate that takes a already fittin set of found peaks Number of peaks fitted based on the found peaks sizestatic intTODO
-
Constructor Details
-
FittingUtils
public FittingUtils()
-
-
Method Details
-
getInitialPeaks
-
getSeededPeakFit
public static Add getSeededPeakFit(List<IdentifiedPeak> foundPeaks, org.eclipse.january.dataset.Dataset xDataSet, org.eclipse.january.dataset.Dataset yDataSet, Class<? extends IPeak> peakClass) A variate that takes a already fittin set of found peaks Number of peaks fitted based on the found peaks size- Parameters:
foundPeaks-xDataSet-yDataSet-peakClass-- Returns:
-
getFittedPeaks
This method runs a fit on data passed in. It reads preferences to determine which algorithm etc. the user prefers. It can take a while to run. Callers of these utils should protect the call by running it from a Job. This method is UI thread safe and may be called in any thread. The x and y data may have been sliced if the user has completed a selection choice which limits the peak fit range. The RegionBounds returns are not computed in y. Instead the peak fitter provides the y values as zero. So XAXIS regions should be created, then Y data is not required. The method also computes x,y abstract data set pairs which are plot fragments for the function plotted over the peak region. These can be plotted to show the user the fitted function, which they may wish to adjust.- Returns:
- Throws:
Exception
-
getQ
-
getIdentifiedPeaks
public static List<IdentifiedPeak> getIdentifiedPeaks(FittedFunctions fittedPeaks, org.eclipse.january.dataset.Dataset x, org.eclipse.core.runtime.IProgressMonitor monitor) throws Exception - Throws:
Exception
-
getPeaksRequired
public static int getPeaksRequired() -
getSmoothing
public static int getSmoothing()TODO- Returns:
-
getOptimizer
-
getPeakClass
-
getPolynomialOrderRequired
public static int getPolynomialOrderRequired() -
getFittedPolynomial
- Throws:
Exception
-