View source: R/Composite_table.R
multinames<- | R Documentation |
Set the multinames attribute of a Composite_table
multinames(x) <- value
multinames(x)
x |
a |
value |
a named vector of ascending integers. The name is the multi-column heading, the integer value is the last column that this heading applies to |
Composite_table, as_multinames()
df_mean <- data.frame(
Species = c("setosa", "versicolor", "virginica"),
length = c(5.01, 5.94, 6.59),
width = c(3.43, 2.77, 2.97)
)
multinames(df_mean) = c("species" = 1, measures = 3)
# .species.. ...measures...
# 1 Species length width
# 2 setosa 5.01 3.43
# 3 versicolor 5.94 2.77
# 4 virginica 6.59 2.97
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.