zipfR (version 0.6-66)

EV-EVm: Expected Frequency Spectrum (zipfR)

Description

EV and EVm are generic methods for computing the expected vocabulary size \(E[V]\) and frequency spectrum \(E[V_m]\) according to a LNRE model (i.e. an object belonging to a subclass of lnre).

When applied to a frequency spectrum (i.e. an object of class spc), these methods perform binomial interpolation (see EV.spc for details), although spc.interp and vgc.interp might be more convenient binomial interpolation functions for most purposes.

Usage

EV(obj, N, ...)
  EVm(obj, m, N, ...)

Arguments

obj

an LNRE model (i.e. an object belonging to a subclass of lnre) or frequency spectrum (i.e. an object of class spc)

m

positive integer value determining the frequency class \(m\) to be returned (or a vector of such values)

N

sample size \(N\) for which the expected vocabulary size and frequency spectrum are calculated (or a vector of sample sizes)

...

additional arguments passed on to the method implementation (see respective manpages for details)

Value

EV returns the expected vocabulary size \(E[V(N)]\) in a sample of \(N\) tokens, and EVm returns the expected spectrum elements \(E[V_m(N)]\), according to the LNRE model given by obj (or according to binomial interpolation).

See Also

See lnre for more information on LNRE models, a listing of available models, and methods for parameter estimation.

The variances of the random variables \(V(N)\) and \(V_m(N)\) can be computed with the methods VV and VVm.

See EV.spc and EVm.spc for more information about the usage of these methods to perform binomial interpolation (but consider using spc.interp and vgc.interp instead).

Examples

Run this code
# NOT RUN {
## see lnre() documentation for examples

# }

Run the code above in your browser using DataLab