Learn R Programming

MAVE (version 1.3.11)

plot.mave: Plot of mave or mave.dim object

Description

Plot the scatterplot of given dimension directions and reponse variables.

Usage

# S3 method for mave
plot(x, dim = 4, plot.method = pairs, ...)

# S3 method for mave.dim plot(x, dim = "dim.min", plot.method = pairs, ...)

Arguments

x

the object returned by mave

dim

the dimension

plot.method

the method for plotting scatter plot. The default is 'pairs'

...

arguments passed to the plot.method.

See Also

mave for computing the dimension reduction space

Examples

Run this code
# NOT RUN {
x = matrix(rnorm(2000),400,5)
beta1 = as.matrix(c(1,1,0,0,0))
beta2 = as.matrix(c(0,0,1,1,0))
err = as.matrix(rnorm(400))
y = (x%*%beta1)^2+x%*%beta2+err
dr = mave(y~x, method = 'meanopg')
dr.dim = mave.dim(dr)
plot(dr,dim=3)
plot(dr.dim)
# }

Run the code above in your browser using DataLab