Skip to content

Bug 7084 - text(x, y, labels) - recycling problems #78

Open
@hturner

Description

Currently text() recycles coordinate pairs when there are more labels than points to plot them at. For example:

plot(1:7); text(1:2, 2:4, LETTERS[1:4])

results in
text_recycling

where "D" is plotted on top of "A" because four labels have been provided (A, B, C, D) but only 3 points ((1, 2), (2, 3), and (1, 4) - the x coordinates are recycled to match the length of y).

This task is to modify text() to drop extra labels with a warning as proposed at the end of Bug 7084.

Metadata

Labels

AssignedIssue has been assigned to 1 or more contributorsGraphicsIssues related to graphicsRIssue should require knowledge of R onlyneeds patchImplement the agreed fix and prepare a patch for review

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions