Print the name and the content of an R object

Share:

Description

Print the name and the content of an R object

Usage

1
printme(x = NULL, prefix = NULL, envir = sys.frame(sys.parent(0)))

Arguments

x

ANY, an R object.

prefix

the prefix to print.

envir

the environment to use.

Author(s)

Xiaobei Zhao

See Also

logme

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
## print an object
x1 <- 1:6
printme(x1)

## print with a prefix
foo <- function(x,envir=sys.frame(sys.parent(0))){
  printme(x,match.call(),envir=envir)
  invisible()
}
foo(1:6)

Want to suggest features or report bugs for rdrr.io? Use the GitHub issue tracker.