Class ImageFitter
java.lang.Object
uk.ac.diamond.scisoft.diffraction.powder.ImageFitter
Direct conversion of I12 Matlab fit_image8.m
Used to find the beam centre from the ellipse major axis length and centre co-ordinates (equations 14 and 16 in J Appl Cryst (2013) 46 1249)
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic double[]fit(org.eclipse.january.dataset.Dataset major, org.eclipse.january.dataset.Dataset x, org.eclipse.january.dataset.Dataset y, double[] line, double pixel) Uses a NelderMeadSimplex with bounds on the beam centre position.
-
Constructor Details
-
ImageFitter
public ImageFitter()
-
-
Method Details
-
fit
public static double[] fit(org.eclipse.january.dataset.Dataset major, org.eclipse.january.dataset.Dataset x, org.eclipse.january.dataset.Dataset y, double[] line, double pixel) Uses a NelderMeadSimplex with bounds on the beam centre position. Best initial parameters are calculated fitting a range of x-centre values.Returns a double array containing the x and y positions, the x used to calculate y using the equation fitted earlier
- Parameters:
major-x-y-line-pixel-- Returns:
- mc
-