Learn R Programming

asymmetry (version 2.0.4)

plot: Plotmethod for Multidimensional sScaling models

Description

Method for a two-dimensional plot of the model. Available rownames are plotted as labels above the points. The slide-vector is shown as an arrow.

Usage

# S3 method for slidevector
plot(x, plot.dim = c(1, 2), yplus = 0, xlab, ylab, ...)
# S3 method for mdsunique
plot(x, plot.dim = c(1, 2), yplus = 0, xlab, ylab, ...)

Arguments

x

Object of class slidevector

plot.dim

A vector with dimensions to be plotted

yplus

Parameter to adjust the vertical position of the label

xlab

Label of x-axis.

ylab

Label of y-axis.

Further plot arguments: see plot for detailed information.

Examples

Run this code
# NOT RUN {
## 2D plot for the slide-vector model on generated data
dis <- matrix(c(1, 2, 3, 4, 5, 6, 2, 8, 9, 3), nrow = 5, ncol = 2)   #configuration
a <- rbind(dis, dis+1.5)                                             #generate slide-vector
test <- as.matrix(dist(a))[1:5, 6:10]                                #extract data
v <- slidevector(test, ndim = 2, itmax = 250, eps = .001)
plot(v)
# }

Run the code above in your browser using DataLab