File: makesymbol.R

package info (click to toggle)
r-cran-jsonlite 1.7.2%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 1,320 kB
  • sloc: ansic: 3,792; sh: 9; makefile: 2
file content (9 lines) | stat: -rw-r--r-- 271 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
# Note: 'symbol' is the same thing as 'name' For some reason, as.name('') gives
# an error, even though it is needed sometimes. This is a workaround
makesymbol <- function(x) {
  if (missing(x) || nchar(x) == 0) {
    return(substitute())
  } else {
    as.name(x)
  }
}