Skip to content

Commit

Permalink
Merge pull request #283 from vincentarelbundock/type_text3
Browse files Browse the repository at this point in the history
Fixing minor error in the `type_text()`
  • Loading branch information
vincentarelbundock authored Dec 27, 2024
2 parents 0b57bd8 + 139a10b commit cba67f0
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 7 deletions.
6 changes: 2 additions & 4 deletions R/type_text.R
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
#' Text annotations plot type
#'
#' @description Type function for adding text annotations to a plot. This function allows
#' you to draw text at specified (x,y) coordinates. If no label is provided, the y-values
#' will be used as the text labels.
#' you to draw text at specified (x,y) coordinates.
#'
#' @param labels Character vector of the same length as the number of x,y coordinates.
#' @param labels Character vector of length 1 or of the same length as the number of x,y coordinates.
#' @param font Font to be used, following [graphics::par()]
#' @inheritParams graphics::text
#' @examples
Expand Down Expand Up @@ -46,4 +45,3 @@ draw_text = function(adj = NULL, pos = NULL, offset = 0.5, vfont = NULL, font =
text(x = ix, y = iy, labels = ilabels, col = icol, adj = adj, pos = pos, offset = offset, vfont = vfont, font = font, cex = cex)
}
}

5 changes: 2 additions & 3 deletions man/type_text.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit cba67f0

Please sign in to comment.