Polyn Class

Description

Implements the TOL grammar "Polyn" in R.

Usage

1
2
3
4
5
6
# Creates a new Polyn Object
Polyn(coeffs, base=0)
## S3 method for class 'Polyn'
as.character(x, ..., backward="B", forward="A")
## S3 method for class 'Polyn'
print(x, ...)

Arguments

coeffs

a vector of coefficients

base

the degree of the first coefficient

x

a Polyn object

...

further arguments

backward

the character to print the lag operator

forward

the character to print the inverse lag operator

Value

The method print prints the expression of the Polyn object and returns it.

See Also

See the generic function print

Examples

1
2
3
4
5
6
# Creates lag polynomial: 1+B^2
p <- Polyn(c(1,0,1)) 
# Gets the Polyn object expression as in TOL
as.character(A+B, forward="F")
# Prints the Polyn object as in TOL
print(A+B, forward="F")