0

In R when I assign a variable with a name starting with . such as .a <- 3, it does not appear in my environment in R Studio. However, when I run the variable .a, it prints 3 to the console.

Why is the variable .a not appearing in my environment but is still able to be accessed?

Phil
  • 7,287
  • 3
  • 36
  • 66
TMilliman
  • 25
  • 4

1 Answers1

0

use the all.names = TRUE in ls

ls(all.names = TRUE)

According to ?ls

all.names - a logical value. If TRUE, all object names are returned. If FALSE, names which begin with a . are omitted.

akrun
  • 874,273
  • 37
  • 540
  • 662