f: Algebraic distance from the center

View source: R/basic_metrics_pc.R

fR Documentation

Algebraic distance from the center

Description

Calculates the algebraic distance between the data points and the mean circle centered at c=(xc, yc) based on calc_r.

Usage

f(c, x, y)

Arguments

c

First estimate of the center coordinates to be optimised (xc,yc).

x

X values of the points.

y

Y values of the points.

Details

Support function used to determine the DBH from a tree point cloud with the functions dbh_pc and dab_pc.

Value

When optimised returns the optimised center estimate of the circle fitting.

Examples

## Not run: 
center_estimate <- optim(par = c(x_m, y_m), fn = f, x = x_dbh, y = y_dbh)

## End(Not run)

lmterryn/ITSMe documentation built on Feb. 4, 2025, 2:21 a.m.