I have a data frame my.df
of the following structure:
A B C
1 1 1 2
2 2 3 4
3 3 5 6
4 NA 7 8
5 NA 9 NA
How to build a box plot from it with column names on x axis and all the values on y?
There are many answers like:
ggplot(melt(my.df), aes(variable, value)) + geom_boxplot()
But I don't understand, what I actually should pass as "variable" and "value". I tried x=colnames(my.df))
and this partially works, however I still have no idea what to do with y.