Skip to content

fitConic

Fit Data to Any Conic Section

v1.2.1 · Aug 28, 2023 · LGPL-3

Description

Fit data to an ellipse, hyperbola, or parabola. Bootstrapping is available when needed. The conic curve can be rotated through an arbitrary angle and the fit will still succeed. Helper functions are provided to convert generator coefficients from one style to another, generate test data sets, rotate conic section parameters, and so on. References include Nikolai Chernov (2014) "Fitting ellipses, circles, and lines by least squares" <https://people.cas.uab.edu/~mosya/cl/>; A. W. Fitzgibbon, M. Pilu, R. B. Fisher (1999) "Direct Least Squares Fitting of Ellipses" IEEE Trans. PAMI, Vol. 21, pages 476-48; N. Chernov, Q. Huang, and H. Ma (2014) "Fitting quadratic curves to data points", British Journal of Mathematics & Computer Science, 4, 33-60; N. Chernov and H. Ma (2011) "Least squares fitting of quadratic curves and surfaces", Computer Vision, Editor S. R. Yoshida, Nova Science Publishers, pp. 285-302.

Downloads

185

Last 30 days

17723rd

185

Last 90 days

185

Last year

CRAN Check Status

14 NOTE
Show all 14 flavors
Flavor Status
r-devel-linux-x86_64-debian-clang NOTE
r-devel-linux-x86_64-debian-gcc NOTE
r-devel-linux-x86_64-fedora-clang NOTE
r-devel-linux-x86_64-fedora-gcc NOTE
r-devel-macos-arm64 NOTE
r-devel-windows-x86_64 NOTE
r-oldrel-macos-arm64 NOTE
r-oldrel-macos-x86_64 NOTE
r-oldrel-windows-x86_64 NOTE
r-patched-linux-x86_64 NOTE
r-release-linux-x86_64 NOTE
r-release-macos-arm64 NOTE
r-release-macos-x86_64 NOTE
r-release-windows-x86_64 NOTE
Check details (14 non-OK)
NOTE r-devel-linux-x86_64-debian-clang

Rd files

checkRd: (-1) fitConic.Rd:66-73: Lost braces
    66 | \code{parA }{vector of the six "ABCDEF" coefficients
       |             ^
checkRd: (-1) fitConic.Rd:67: Lost braces
    67 | \code{RSS }{'root sum square' figure of merit describing the relative fit quality}
       |            ^
checkRd: (-1) fitConic.Rd:68: Lost braces
    68 | \code{iters }{number of iterations at convergence}
       |              ^
checkRd: (-1) fitConic.Rd:69-71: Lost braces
    69 | \code{exitCode }{1 means ellipse, 2 means hyperbola, 3 means parabola.
       |                 ^
checkRd: (-1) rotateA.Rd:59: Lost braces; missing escapes or markup?
    59 | For \code{xyrot} {a Nx2 array of the x,y coordinates of the rotated data set. }
       |                  ^
NOTE r-devel-linux-x86_64-debian-gcc

Rd files

checkRd: (-1) fitConic.Rd:66-73: Lost braces
    66 | \code{parA }{vector of the six "ABCDEF" coefficients
       |             ^
checkRd: (-1) fitConic.Rd:67: Lost braces
    67 | \code{RSS }{'root sum square' figure of merit describing the relative fit quality}
       |            ^
checkRd: (-1) fitConic.Rd:68: Lost braces
    68 | \code{iters }{number of iterations at convergence}
       |              ^
checkRd: (-1) fitConic.Rd:69-71: Lost braces
    69 | \code{exitCode }{1 means ellipse, 2 means hyperbola, 3 means parabola.
       |                 ^
checkRd: (-1) rotateA.Rd:59: Lost braces; missing escapes or markup?
    59 | For \code{xyrot} {a Nx2 array of the x,y coordinates of the rotated data set. }
       |                  ^
NOTE r-devel-linux-x86_64-fedora-clang

Rd files

checkRd: (-1) fitConic.Rd:66-73: Lost braces
    66 | \code{parA }{vector of the six "ABCDEF" coefficients
       |             ^
checkRd: (-1) fitConic.Rd:67: Lost braces
    67 | \code{RSS }{'root sum square' figure of merit describing the relative fit quality}
       |            ^
checkRd: (-1) fitConic.Rd:68: Lost braces
    68 | \code{iters }{number of iterations at convergence}
       |              ^
checkRd: (-1) fitConic.Rd:69-71: Lost braces
    69 | \code{exitCode }{1 means ellipse, 2 means hyperbola, 3 means parabola.
       |                 ^
checkRd: (-1) rotateA.Rd:59: Lost braces; missing escapes or markup?
    59 | For \code{xyrot} {a Nx2 array of the x,y coordinates of the rotated data set. }
       |                  ^
NOTE r-devel-linux-x86_64-fedora-gcc

Rd files

checkRd: (-1) fitConic.Rd:66-73: Lost braces
    66 | \code{parA }{vector of the six "ABCDEF" coefficients
       |             ^
checkRd: (-1) fitConic.Rd:67: Lost braces
    67 | \code{RSS }{'root sum square' figure of merit describing the relative fit quality}
       |            ^
checkRd: (-1) fitConic.Rd:68: Lost braces
    68 | \code{iters }{number of iterations at convergence}
       |              ^
checkRd: (-1) fitConic.Rd:69-71: Lost braces
    69 | \code{exitCode }{1 means ellipse, 2 means hyperbola, 3 means parabola.
       |                 ^
checkRd: (-1) rotateA.Rd:59: Lost braces; missing escapes or markup?
    59 | For \code{xyrot} {a Nx2 array of the x,y coordinates of the rotated data set. }
       |                  ^
NOTE r-devel-macos-arm64

Rd files

checkRd: (-1) fitConic.Rd:66-73: Lost braces
    66 | \code{parA }{vector of the six "ABCDEF" coefficients
       |             ^
checkRd: (-1) fitConic.Rd:67: Lost braces
    67 | \code{RSS }{'root sum square' figure of merit describing the relative fit quality}
       |            ^
checkRd: (-1) fitConic.Rd:68: Lost braces
    68 | \code{iters }{number of iterations at convergence}
       |              ^
checkRd: (-1) fitConic.Rd:69-71: Lost braces
    69 | \code{exitCode }{1 means ellipse, 2 means hyperbola, 3 means parabola.
       |                 ^
checkRd: (-1) rotateA.Rd:59: Lost braces; missing escapes or markup?
    59 | For \code{xyrot} {a Nx2 array of the x,y coordinates of the rotated data set. }
       |                  ^
NOTE r-devel-windows-x86_64

Rd files

checkRd: (-1) fitConic.Rd:66-73: Lost braces
    66 | \code{parA }{vector of the six "ABCDEF" coefficients
       |             ^
checkRd: (-1) fitConic.Rd:67: Lost braces
    67 | \code{RSS }{'root sum square' figure of merit describing the relative fit quality}
       |            ^
checkRd: (-1) fitConic.Rd:68: Lost braces
    68 | \code{iters }{number of iterations at convergence}
       |              ^
checkRd: (-1) fitConic.Rd:69-71: Lost braces
    69 | \code{exitCode }{1 means ellipse, 2 means hyperbola, 3 means parabola.
       |                 ^
checkRd: (-1) rotateA.Rd:59: Lost braces; missing escapes or markup?
    59 | For \code{xyrot} {a Nx2 array of the x,y coordinates of the rotated data set. }
       |                  ^
NOTE r-oldrel-macos-arm64

Rd files

checkRd: (-1) fitConic.Rd:66-73: Lost braces
    66 | \code{parA }{vector of the six "ABCDEF" coefficients
       |             ^
checkRd: (-1) fitConic.Rd:67: Lost braces
    67 | \code{RSS }{'root sum square' figure of merit describing the relative fit quality}
       |            ^
checkRd: (-1) fitConic.Rd:68: Lost braces
    68 | \code{iters }{number of iterations at convergence}
       |              ^
checkRd: (-1) fitConic.Rd:69-71: Lost braces
    69 | \code{exitCode }{1 means ellipse, 2 means hyperbola, 3 means parabola.
       |                 ^
checkRd: (-1) rotateA.Rd:59: Lost braces; missing escapes or markup?
    59 | For \code{xyrot} {a Nx2 array of the x,y coordinates of the rotated data set. }
       |                  ^
NOTE r-oldrel-macos-x86_64

Rd files

checkRd: (-1) fitConic.Rd:66-73: Lost braces
    66 | \code{parA }{vector of the six "ABCDEF" coefficients
       |             ^
checkRd: (-1) fitConic.Rd:67: Lost braces
    67 | \code{RSS }{'root sum square' figure of merit describing the relative fit quality}
       |            ^
checkRd: (-1) fitConic.Rd:68: Lost braces
    68 | \code{iters }{number of iterations at convergence}
       |              ^
checkRd: (-1) fitConic.Rd:69-71: Lost braces
    69 | \code{exitCode }{1 means ellipse, 2 means hyperbola, 3 means parabola.
       |                 ^
checkRd: (-1) rotateA.Rd:59: Lost braces; missing escapes or markup?
    59 | For \code{xyrot} {a Nx2 array of the x,y coordinates of the rotated data set. }
       |                  ^
NOTE r-oldrel-windows-x86_64

Rd files

checkRd: (-1) fitConic.Rd:66-73: Lost braces
    66 | \code{parA }{vector of the six "ABCDEF" coefficients
       |             ^
checkRd: (-1) fitConic.Rd:67: Lost braces
    67 | \code{RSS }{'root sum square' figure of merit describing the relative fit quality}
       |            ^
checkRd: (-1) fitConic.Rd:68: Lost braces
    68 | \code{iters }{number of iterations at convergence}
       |              ^
checkRd: (-1) fitConic.Rd:69-71: Lost braces
    69 | \code{exitCode }{1 means ellipse, 2 means hyperbola, 3 means parabola.
       |                 ^
checkRd: (-1) rotateA.Rd:59: Lost braces; missing escapes or markup?
    59 | For \code{xyrot} {a Nx2 array of the x,y coordinates of the rotated data set. }
       |                  ^
NOTE r-patched-linux-x86_64

Rd files

checkRd: (-1) fitConic.Rd:66-73: Lost braces
    66 | \code{parA }{vector of the six "ABCDEF" coefficients
       |             ^
checkRd: (-1) fitConic.Rd:67: Lost braces
    67 | \code{RSS }{'root sum square' figure of merit describing the relative fit quality}
       |            ^
checkRd: (-1) fitConic.Rd:68: Lost braces
    68 | \code{iters }{number of iterations at convergence}
       |              ^
checkRd: (-1) fitConic.Rd:69-71: Lost braces
    69 | \code{exitCode }{1 means ellipse, 2 means hyperbola, 3 means parabola.
       |                 ^
checkRd: (-1) rotateA.Rd:59: Lost braces; missing escapes or markup?
    59 | For \code{xyrot} {a Nx2 array of the x,y coordinates of the rotated data set. }
       |                  ^
NOTE r-release-linux-x86_64

Rd files

checkRd: (-1) fitConic.Rd:66-73: Lost braces
    66 | \code{parA }{vector of the six "ABCDEF" coefficients
       |             ^
checkRd: (-1) fitConic.Rd:67: Lost braces
    67 | \code{RSS }{'root sum square' figure of merit describing the relative fit quality}
       |            ^
checkRd: (-1) fitConic.Rd:68: Lost braces
    68 | \code{iters }{number of iterations at convergence}
       |              ^
checkRd: (-1) fitConic.Rd:69-71: Lost braces
    69 | \code{exitCode }{1 means ellipse, 2 means hyperbola, 3 means parabola.
       |                 ^
checkRd: (-1) rotateA.Rd:59: Lost braces; missing escapes or markup?
    59 | For \code{xyrot} {a Nx2 array of the x,y coordinates of the rotated data set. }
       |                  ^
NOTE r-release-macos-arm64

Rd files

checkRd: (-1) fitConic.Rd:66-73: Lost braces
    66 | \code{parA }{vector of the six "ABCDEF" coefficients
       |             ^
checkRd: (-1) fitConic.Rd:67: Lost braces
    67 | \code{RSS }{'root sum square' figure of merit describing the relative fit quality}
       |            ^
checkRd: (-1) fitConic.Rd:68: Lost braces
    68 | \code{iters }{number of iterations at convergence}
       |              ^
checkRd: (-1) fitConic.Rd:69-71: Lost braces
    69 | \code{exitCode }{1 means ellipse, 2 means hyperbola, 3 means parabola.
       |                 ^
checkRd: (-1) rotateA.Rd:59: Lost braces; missing escapes or markup?
    59 | For \code{xyrot} {a Nx2 array of the x,y coordinates of the rotated data set. }
       |                  ^
NOTE r-release-macos-x86_64

Rd files

checkRd: (-1) fitConic.Rd:66-73: Lost braces
    66 | \code{parA }{vector of the six "ABCDEF" coefficients
       |             ^
checkRd: (-1) fitConic.Rd:67: Lost braces
    67 | \code{RSS }{'root sum square' figure of merit describing the relative fit quality}
       |            ^
checkRd: (-1) fitConic.Rd:68: Lost braces
    68 | \code{iters }{number of iterations at convergence}
       |              ^
checkRd: (-1) fitConic.Rd:69-71: Lost braces
    69 | \code{exitCode }{1 means ellipse, 2 means hyperbola, 3 means parabola.
       |                 ^
checkRd: (-1) rotateA.Rd:59: Lost braces; missing escapes or markup?
    59 | For \code{xyrot} {a Nx2 array of the x,y coordinates of the rotated data set. }
       |                  ^
NOTE r-release-windows-x86_64

Rd files

checkRd: (-1) fitConic.Rd:66-73: Lost braces
    66 | \code{parA }{vector of the six "ABCDEF" coefficients
       |             ^
checkRd: (-1) fitConic.Rd:67: Lost braces
    67 | \code{RSS }{'root sum square' figure of merit describing the relative fit quality}
       |            ^
checkRd: (-1) fitConic.Rd:68: Lost braces
    68 | \code{iters }{number of iterations at convergence}
       |              ^
checkRd: (-1) fitConic.Rd:69-71: Lost braces
    69 | \code{exitCode }{1 means ellipse, 2 means hyperbola, 3 means parabola.
       |                 ^
checkRd: (-1) rotateA.Rd:59: Lost braces; missing escapes or markup?
    59 | For \code{xyrot} {a Nx2 array of the x,y coordinates of the rotated data set. }
       |                  ^

Check History

NOTE 0 OK · 14 NOTE · 0 WARNING · 0 ERROR · 0 FAILURE Mar 9, 2026
NOTE r-devel-linux-x86_64-debian-clang

Rd files

checkRd: (-1) fitConic.Rd:66-73: Lost braces
    66 | \code{parA }{vector of the six "ABCDEF" coefficients
       |             ^
checkRd: (-1) fitConic.Rd:67: Lost braces
    67 | \code{RSS }{'root sum square' figure of merit describing the relative fit quality}
       |            ^
checkRd: (-1) fitConic.Rd:68: Lost braces
    68 | \code{iters }{number of iterations at convergence}
       |              ^
checkRd: (-1) fitConic.Rd:69-71: Lost braces
    69 | \code{exitCode }{1 means ellipse, 
NOTE r-devel-linux-x86_64-debian-gcc

Rd files

checkRd: (-1) fitConic.Rd:66-73: Lost braces
    66 | \code{parA }{vector of the six "ABCDEF" coefficients
       |             ^
checkRd: (-1) fitConic.Rd:67: Lost braces
    67 | \code{RSS }{'root sum square' figure of merit describing the relative fit quality}
       |            ^
checkRd: (-1) fitConic.Rd:68: Lost braces
    68 | \code{iters }{number of iterations at convergence}
       |              ^
checkRd: (-1) fitConic.Rd:69-71: Lost braces
    69 | \code{exitCode }{1 means ellipse, 
NOTE r-devel-linux-x86_64-fedora-clang

Rd files

checkRd: (-1) fitConic.Rd:66-73: Lost braces
    66 | \code{parA }{vector of the six "ABCDEF" coefficients
       |             ^
checkRd: (-1) fitConic.Rd:67: Lost braces
    67 | \code{RSS }{'root sum square' figure of merit describing the relative fit quality}
       |            ^
checkRd: (-1) fitConic.Rd:68: Lost braces
    68 | \code{iters }{number of iterations at convergence}
       |              ^
checkRd: (-1) fitConic.Rd:69-71: Lost braces
    69 | \code{exitCode }{1 means ellipse, 
NOTE r-devel-linux-x86_64-fedora-gcc

Rd files

checkRd: (-1) fitConic.Rd:66-73: Lost braces
    66 | \code{parA }{vector of the six "ABCDEF" coefficients
       |             ^
checkRd: (-1) fitConic.Rd:67: Lost braces
    67 | \code{RSS }{'root sum square' figure of merit describing the relative fit quality}
       |            ^
checkRd: (-1) fitConic.Rd:68: Lost braces
    68 | \code{iters }{number of iterations at convergence}
       |              ^
checkRd: (-1) fitConic.Rd:69-71: Lost braces
    69 | \code{exitCode }{1 means ellipse, 
NOTE r-devel-macos-arm64

Rd files

checkRd: (-1) fitConic.Rd:66-73: Lost braces
    66 | \code{parA }{vector of the six "ABCDEF" coefficients
       |             ^
checkRd: (-1) fitConic.Rd:67: Lost braces
    67 | \code{RSS }{'root sum square' figure of merit describing the relative fit quality}
       |            ^
checkRd: (-1) fitConic.Rd:68: Lost braces
    68 | \code{iters }{number of iterations at convergence}
       |              ^
checkRd: (-1) fitConic.Rd:69-71: Lost braces
    69 | \code{exitCode }{1 means ellipse, 
NOTE r-devel-windows-x86_64

Rd files

checkRd: (-1) fitConic.Rd:66-73: Lost braces
    66 | \code{parA }{vector of the six "ABCDEF" coefficients
       |             ^
checkRd: (-1) fitConic.Rd:67: Lost braces
    67 | \code{RSS }{'root sum square' figure of merit describing the relative fit quality}
       |            ^
checkRd: (-1) fitConic.Rd:68: Lost braces
    68 | \code{iters }{number of iterations at convergence}
       |              ^
checkRd: (-1) fitConic.Rd:69-71: Lost braces
    69 | \code{exitCode }{1 means ellipse, 
NOTE r-patched-linux-x86_64

Rd files

checkRd: (-1) fitConic.Rd:66-73: Lost braces
    66 | \code{parA }{vector of the six "ABCDEF" coefficients
       |             ^
checkRd: (-1) fitConic.Rd:67: Lost braces
    67 | \code{RSS }{'root sum square' figure of merit describing the relative fit quality}
       |            ^
checkRd: (-1) fitConic.Rd:68: Lost braces
    68 | \code{iters }{number of iterations at convergence}
       |              ^
checkRd: (-1) fitConic.Rd:69-71: Lost braces
    69 | \code{exitCode }{1 means ellipse, 
NOTE r-release-linux-x86_64

Rd files

checkRd: (-1) fitConic.Rd:66-73: Lost braces
    66 | \code{parA }{vector of the six "ABCDEF" coefficients
       |             ^
checkRd: (-1) fitConic.Rd:67: Lost braces
    67 | \code{RSS }{'root sum square' figure of merit describing the relative fit quality}
       |            ^
checkRd: (-1) fitConic.Rd:68: Lost braces
    68 | \code{iters }{number of iterations at convergence}
       |              ^
checkRd: (-1) fitConic.Rd:69-71: Lost braces
    69 | \code{exitCode }{1 means ellipse, 
NOTE r-release-macos-arm64

Rd files

checkRd: (-1) fitConic.Rd:66-73: Lost braces
    66 | \code{parA }{vector of the six "ABCDEF" coefficients
       |             ^
checkRd: (-1) fitConic.Rd:67: Lost braces
    67 | \code{RSS }{'root sum square' figure of merit describing the relative fit quality}
       |            ^
checkRd: (-1) fitConic.Rd:68: Lost braces
    68 | \code{iters }{number of iterations at convergence}
       |              ^
checkRd: (-1) fitConic.Rd:69-71: Lost braces
    69 | \code{exitCode }{1 means ellipse, 
NOTE r-release-macos-x86_64

Rd files

checkRd: (-1) fitConic.Rd:66-73: Lost braces
    66 | \code{parA }{vector of the six "ABCDEF" coefficients
       |             ^
checkRd: (-1) fitConic.Rd:67: Lost braces
    67 | \code{RSS }{'root sum square' figure of merit describing the relative fit quality}
       |            ^
checkRd: (-1) fitConic.Rd:68: Lost braces
    68 | \code{iters }{number of iterations at convergence}
       |              ^
checkRd: (-1) fitConic.Rd:69-71: Lost braces
    69 | \code{exitCode }{1 means ellipse, 
NOTE r-release-windows-x86_64

Rd files

checkRd: (-1) fitConic.Rd:66-73: Lost braces
    66 | \code{parA }{vector of the six "ABCDEF" coefficients
       |             ^
checkRd: (-1) fitConic.Rd:67: Lost braces
    67 | \code{RSS }{'root sum square' figure of merit describing the relative fit quality}
       |            ^
checkRd: (-1) fitConic.Rd:68: Lost braces
    68 | \code{iters }{number of iterations at convergence}
       |              ^
checkRd: (-1) fitConic.Rd:69-71: Lost braces
    69 | \code{exitCode }{1 means ellipse, 
NOTE r-oldrel-macos-arm64

Rd files

checkRd: (-1) fitConic.Rd:66-73: Lost braces
    66 | \code{parA }{vector of the six "ABCDEF" coefficients
       |             ^
checkRd: (-1) fitConic.Rd:67: Lost braces
    67 | \code{RSS }{'root sum square' figure of merit describing the relative fit quality}
       |            ^
checkRd: (-1) fitConic.Rd:68: Lost braces
    68 | \code{iters }{number of iterations at convergence}
       |              ^
checkRd: (-1) fitConic.Rd:69-71: Lost braces
    69 | \code{exitCode }{1 means ellipse, 
NOTE r-oldrel-macos-x86_64

Rd files

checkRd: (-1) fitConic.Rd:66-73: Lost braces
    66 | \code{parA }{vector of the six "ABCDEF" coefficients
       |             ^
checkRd: (-1) fitConic.Rd:67: Lost braces
    67 | \code{RSS }{'root sum square' figure of merit describing the relative fit quality}
       |            ^
checkRd: (-1) fitConic.Rd:68: Lost braces
    68 | \code{iters }{number of iterations at convergence}
       |              ^
checkRd: (-1) fitConic.Rd:69-71: Lost braces
    69 | \code{exitCode }{1 means ellipse, 
NOTE r-oldrel-windows-x86_64

Rd files

checkRd: (-1) fitConic.Rd:66-73: Lost braces
    66 | \code{parA }{vector of the six "ABCDEF" coefficients
       |             ^
checkRd: (-1) fitConic.Rd:67: Lost braces
    67 | \code{RSS }{'root sum square' figure of merit describing the relative fit quality}
       |            ^
checkRd: (-1) fitConic.Rd:68: Lost braces
    68 | \code{iters }{number of iterations at convergence}
       |              ^
checkRd: (-1) fitConic.Rd:69-71: Lost braces
    69 | \code{exitCode }{1 means ellipse, 

Dependency Network

Dependencies Reverse dependencies pracma fitConic

Version History

new 1.2.1 Mar 10, 2026