meltWholeDF | R Documentation |
The function converts wide format data which is either a data.frame or a matrix (with dimnames present) to a long format structure. The output data.frame have three columns: X, Y, and Measure. These are: column names, row names and values of the input object, respectively.
meltWholeDF(df)
df |
data.frame |
This function is particularly useful to prepare data for plotting with ggplot2 package.
data.frame
Małgorzata Oleś <malgorzata.oles@embl.de>
df = data.frame(A=1:4, B=4:7, row.names=letters[1:4])
meltWholeDF(df)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.