Learn R Programming

matRiks (version 0.1.3)

ellipse: Coordinates of an ellipse

Description

Define the coordinates for drawing an ellipse

Usage

ellipse(
  size.x = 10,
  size.y = 7,
  rot = 0,
  shd = NA,
  pos.x = 0,
  pos.y = 0,
  vis = 1,
  lty = 1,
  lwd = 3
)

Value

Return the coordinates for drawing a ellipse

Arguments

size.x

numeric, define the semi-major axis of the ellipse within which the figure is inscribed. Default is 10

size.y

numeric, define the semi-minor axis of the ellipse within which the figure is inscribed. Default is 7

rot

define the rotation. Default is 0

shd

character, define the shading of the figure. Default is NA which results in a transparent figure

pos.x

numeric, position on the x axis. Default is 0

pos.y

numeric, position the y axis, Default is 0

vis

Visibility of the figure. Default is 1, making the figure visible. To hide the figure, change it to 0

lty

integer, define the line type of the figure, default is 1 (solid line).

lwd

integer, define the line width of the figure. Default is 3

Examples

Run this code
# return the default coordinates for drawing an ellipse
ellipse()
# change the coordinates for drawing a smaller ellipse
ellipse(size.x = 5, size.y = 3)

Run the code above in your browser using DataLab