Learn R Programming

pcds (version 0.1.4)

plot.Planes: Plot a Planes object

Description

Plots the plane together with the defining 3D points.

Usage

# S3 method for Planes
plot(x, xlab = "x", ylab = "y", zlab = "z", ...)

Value

None

Arguments

x

Object of class Planes.

xlab, ylab, zlab

Titles for the \(x\), \(y\), and \(z\) axes, respectively (default is xlab="x", ylab="y", and zlab="z").

...

Additional parameters for plot.

See Also

print.Planes, summary.Planes, and print.summary.Planes

Examples

Run this code
A<-c(1,10,3); B<-c(1,1,3); C<-c(3,9,12)
pts<-rbind(A,B,C)

xr<-range(pts[,1]); yr<-range(pts[,2])
xf<-(xr[2]-xr[1])*.1 #how far to go at the lower and upper ends in the x-coordinate
yf<-(yr[2]-yr[1])*.1 #how far to go at the lower and upper ends in the y-coordinate
x<-seq(xr[1]-xf,xr[2]+xf,l=100)
y<-seq(yr[1]-yf,yr[2]+yf,l=100)

plABC<-Plane(A,B,C,x,y)
plABC
plot(plABC)

Run the code above in your browser using DataLab