Add a circle to the image

add_circle(
  input,
  x = 0.5,
  y = 0.5,
  r = 1,
  color = "black",
  fill = "none",
  line_width = 1,
  openfile = TRUE,
  output = input
)

Arguments

input

File name of .svg file to input

x

x-coordinate of circle center (0 to 1)

y

y-coordinate of circle center (0 to 1)

r

radius (0 to 1)

color

line color

fill

fill color

line_width

width of line

openfile

Open file in default program for .svg format. Defaults to FALSE.

output

File name of .svg file to output. Default is to overwrite the input file.

Value

output name

Examples

.old_wd <- setwd(tempdir()) spiro(fixed_radius = 3, cycling_radius = 1, file = "add_circle_example.svg", colors = "red") %>% add_circle(r = 0.308, fill = "white", color = "white") setwd(.old_wd)