Learn R Programming

imagefx (version 0.4.1)

points2: Plot points on image

Description

This is a plotting function that should be used with image2. This function is in line with image2, which locates the origin to the top-left corner as opposed to the bottom-left as image does.

Usage

points2(x,y,img,...)

Arguments

x

x location of points to plot

y

y location of points to plot

img

original image (matrix) which was plotted using image2. This is supplied simply for dimensional information.

...

additional arguments to be passed to points.

Value

Nothing. This is a plotting function.

See Also

image2

Examples

Run this code
# NOT RUN {
## build a test matrix
mat = matrix(0,nrow=20,ncol=20)
mat[1,1]=1

image2(mat,axes=FALSE,xlab='',ylab='')
points2(1,1,img=mat,col='red',pch=16)
# }

Run the code above in your browser using DataLab