powered by
as_line2d() casts to a Line2D object.
as_line2d()
as_line2d(...)# S3 method for numeric as_line2d(a, b, c, ...)# S3 method for angle as_line2d(theta, p1 = as_coord2d("origin"), ...)# S3 method for character as_line2d(x, ...)# S3 method for Coord2D as_line2d(normal, p1 = as_coord3d("origin"), p2, ...)# S3 method for Line2D as_line2d(line, ...)# S3 method for Point1D as_line2d(point, b = 0, ...)
# S3 method for numeric as_line2d(a, b, c, ...)
# S3 method for angle as_line2d(theta, p1 = as_coord2d("origin"), ...)
# S3 method for character as_line2d(x, ...)
# S3 method for Coord2D as_line2d(normal, p1 = as_coord3d("origin"), p2, ...)
# S3 method for Line2D as_line2d(line, ...)
# S3 method for Point1D as_line2d(point, b = 0, ...)
Passed to other function such as as_coord2d().
as_coord2d()
Numeric vectors that parameterize the line via the equation a * x + b * y + c = 0. Note if y = m * x + b then m * x + 1 * y + -b = 0.
a * x + b * y + c = 0
y = m * x + b
m * x + 1 * y + -b = 0
Angle of the line represented by an angle() vector.
angle()
Point on the line represented by a Coord2D class object.
A (character) vector to be cast to a Line2D object
Normal vector to the line represented by a Coord2D class object. p2 should be missing.
p2
Another point on the line represented by a Coord2D class object.
A Line2D object
A Point1D object
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)
Run the code above in your browser using DataLab