N-V-Vm.spc {zipfR} | R Documentation |
Access Methods for Frequency Spectra (zipfR)
Description
Return the sample size (N.spc
), vocabulary size (V.spc
)
and class sizes (Vm.spc
) of the frequency spectrum represented
by a spc
object. For an expected spectrum with variance
information, VV.spc
returns the variance of the expected
spectrum size and VVm.spc
the variances of individual spectrum
elements.
Note that these functions are not user-visible. They can be called
implicitly through the generic methods N
, V
, Vm
,
VV
and VVm
, applied to an object of type spc
.
Usage
## S3 method for class 'spc'
N(obj, ...)
## S3 method for class 'spc'
V(obj, ...)
## S3 method for class 'spc'
Vm(obj, m, ...)
## S3 method for class 'spc'
VV(obj, N=NA, ...)
## S3 method for class 'spc'
VVm(obj, m, N=NA, ...)
Arguments
obj |
an object of class |
m |
positive integer value determining the frequency class
|
N |
not applicable (this argument of the generic method is not
used by the implementation for |
... |
additional arguments passed on from generic method will be ignored |
Details
VV.spc
a VVm.spc
will fail if the object obj
is
not an expected frequency spectrum with variance data.
For an incomplete frequency spectrum, Vm.spc
(and
VVm.spc
) will return NA
for all spectrum elements that
are not listed in the object (i.e. for m > m.max
).
Value
N.spc
returns the sample size N
, V.spc
returns the
vocabulary size V
(or expected vocabulary size E[V]
), and
Vm.spc
returns a vector of class sizes V_m
(ot the
expected spectrum elements E[V_m]
).
For an expected spectrum with variances, VV.spc
returns the
variance \mathop{Var}[V]
of the expected vocabulary
size, and VVm.spc
returns variances
\mathop{Var}[V_m]
of the spectrum elements.
See Also
N
, V
, Vm
, VV
,
VVm
for the generic methods and links to other
implementations
spc
for details on frequency spectrum objects and links
to other relevant functions