Line2D: 2D lines R6 Class

Line2DR Documentation

2D lines R6 Class

Description

Line2D is an R6::R6Class() object representing two-dimensional lines.

Public fields

a

Numeric vector that parameterizes the line via the equation a * x + b * y + c = 0.

b

Numeric vector that parameterizes the line via the equation a * x + b * y + c = 0.

c

Numeric vector that parameterizes the line via the equation a * x + b * y + c = 0.

Methods

Public methods


Method new()

Usage
Line2D$new(a, b, c)
Arguments
a

Numeric vector that parameterizes the line via the equation a * x + b * y + c = 0.

b

Numeric vector that parameterizes the line via the equation a * x + b * y + c = 0.

c

Numeric vector that parameterizes the line via the equation a * x + b * y + c = 0.


Method print()

Usage
Line2D$print(n = NULL, ...)
Arguments
n

Number of lines to print. If NULL print all of them.

...

Passed to format.default().


Method clone()

The objects of this class are cloneable with this method.

Usage
Line2D$clone(deep = FALSE)
Arguments
deep

Whether to make a deep clone.

Examples

p1 <- as_coord2d(x = 5, y = 10)
p2 <- as_coord2d(x = 7, y = 12)
theta <- degrees(45)
as_line2d(theta, p1)
as_line2d(p1, p2)

affiner documentation built on April 4, 2025, 4:42 a.m.