R/to_clipboard.r

Defines functions to_clipboard

Documented in to_clipboard

#' to_clipboard
#'
#' Sends a formatted corx table to the clipboard so that it can be pasted into excel.
#' @param x a corx object, matrix, or data.frame
#' @param ... additional arguments passed to 'clipr::write_clip'
#' @export to_clipboard

to_clipboard <- function(x, ...) {

  if("corx" %in% class(x)){
  clipr::write_clip(x$apa, ...)
  }else{
    clipr::write_clip(x, ...)
  }

}

Try the corx package in your browser

Any scripts or data that you put into this service are public.

corx documentation built on July 9, 2023, 6:32 p.m.