calcmode {MetaLandSim}R 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

[Package MetaLandSim version 2.0.0 Index]