Gets the number of terms of an object.
# Default S3 method
nterms(x, ...)
Arguments
- x
An object.
- ...
Other arguments passed to methods.
Value
A integer scalar of the number of terms.
Examples
nterms(term("alpha[1]", "alpha[2]", "beta[1,1]", "beta[2,1]"))
#> [1] 4
nterms(term("alpha[1]", "alpha[1]", "beta[1,1]", "beta[1,1]"))
#> [1] 4