get the name of dataframe in r code example
Example 1: r get name of column in data frame
colnames(<dataframe>)
#or
names(<dataframe>)
Example 2: return the name of the dataset in r
# in r
a <- data.frame()
deparse(substitute(a))
colnames(<dataframe>)
#or
names(<dataframe>)
# in r
a <- data.frame()
deparse(substitute(a))