add_line {scplot} | R Documentation |
Add line to an scplot
Description
Add line to an scplot
Usage
add_line(
object,
case = 1,
x0 = NULL,
y0 = NULL,
x1 = NULL,
y1 = NULL,
hline = NULL,
vline = NULL,
color = "black",
linewidth = 0.7,
linetype = "solid"
)
Arguments
object |
An scplot object (class |
case |
Numerical vector with the case number or character string. |
x0 |
Origin x position of the line. |
y0 |
Origin y position of the line. |
x1 |
End x position of the line. |
y1 |
End y position of the line. |
hline |
y position of horizontal line. |
vline |
x position of vertical line. |
color |
A character string or a number defining the color of an element. |
linewidth |
A number with the width of the line. |
linetype |
A character string with the line type: |
Value
An object of class scplot
(seescplot()
) with added element
lines
.
Examples
data(exampleAB, package = "scan")
p1 <- scplot(exampleAB$Anja) |>
add_line(hline = 70, color = "darkred") |>
add_line(vline = 3, color = "blue") |>
add_line(x0 = 1, y0 = 70, x1 = 4, y1 = 80, color = "green")
[Package scplot version 0.4.0 Index]