calcmode: Function for mode estimation of a continuous variable

View source: R/calcmode.r

calcmodeR Documentation

Function for mode estimation of a continuous variable

Description

Derives the mode, estimating the value of a continuous variable.

Usage

calcmode(data,adjust=1)

Arguments

data

vector used to estimate the mode.

adjust

increase this value to make the density estimate smoother.

Value

Returns the numeric value of the mode.

Author(s)

Adapted from https://stat.ethz.ch/pipermail/r-help/2008-August/172323.html.

Examples

vect1 = rchisq(1000,df=3)
calcmode(vect1)
vect1

MetaLandSim documentation built on Jan. 13, 2023, 1:11 a.m.