Identify each dataframe in a list with the name of the corresponding list item.
name_dfs(dfs, name = "name")
dfs | A list of dataframes. |
---|---|
name | Names of the columns that store the names and values. |
A list of dataframes.
#> $a #> x name #> 1 1 a #> #> $b #> x name #> 1 1 b #>name_dfs(dfs, "custom_name")#> $a #> x custom_name #> 1 1 a #> #> $b #> x custom_name #> 1 1 b #>#> $df1 #> x name #> 1 1 df1 #> #> $df2 #> x name #> 1 1 df2 #>