varnames_snippet | R Documentation |
The if the data frame has 3 columns named "x", "y" and "name with space" the function cats and on windows also copies to your clipboard the following code:
varnames_snippet(x)
x |
A data frame or other objects with |
c("x","y","`name with space`")
This can be helpful to specify vectors of control
variables when using gf
. If there are
many variables it is just easier to remove not-used variables
from the created code snippet than to write down
manually all used variables.
df = data.frame(x=1,y=5,z=4,`a b`=4)
varnames_snippet(df)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.