Learn R Programming

sivipm (version 1.1-4.2)

bind.polyX: Bind Several polyX Objects

Description

Bind several objects of class '>polyX.

Usage

# S4 method for polyX
bind(x, …)

Arguments

x

Object of class '>polyX.

Objects of class '>polyX to be binded to x. As many as required. It is assumed that they have been built on the same dataset of inputs.

Value

An object of class '>polyX, coding for a polynomial including the monomials of all the polynomials in the argument list. Its degree is the maximal degree of these polynomials. Duplicated monomials are removed.

See Also

takeoff.polyX

Examples

Run this code
# NOT RUN {
# Create first polynomial
P <- vect2polyX(cornell0[,1:3],c("1","2","3", "3*3*3", "3*3"))
# Create second polynomial
P2 <- vect2polyX(cornell0[,1:3], c("1","2","3", "2*3"))
# Bind them: PP=X1 + X2 + X3 + X3*X3*X3 + X3*X3 + X2*X3
PP <- bind.polyX(P, P2)
# }

Run the code above in your browser using DataLab