attract_by_distance: Move points towards each other an absolute distance

View source: R/position-attractsegment.R

attract_by_distanceR Documentation

Move points towards each other an absolute distance

Description

Move points towards each other an absolute distance

Usage

attract_by_distance(x, xend, y, yend, length_start, length_end)

Arguments

x, xend, y, yend

The coordinates of the start and end of the segment

length_start, length_end

How much to take off the start and end of the line (in the units of the data; beware this can make little sense unless both axes have the same units)

Value

A named list of new coordinates for the start and end of the line


ggarchery documentation built on May 29, 2024, 10:27 a.m.