This is my data.frame,
> head(dat)
word value number name
1 10 0.001 30 gi|378283288
2 15 0.001 17 gi|378283288
3 20 0.001 16 gi|378283288
4 25 0.001 14 gi|378283288
5 30 0.001 12 gi|378283288
6 10 0.010 38 gi|378283288
> tail(dat)
word value number name
120 30 0.5 27 gi|378285158
121 10 1.0 34 gi|378285158
122 15 1.0 31 gi|378285158
123 20 1.0 27 gi|378285158
124 25 1.0 27 gi|378285158
125 30 1.0 27 gi|378285158
I want to present it in a bar graph. I explored the options, but not succeeded yet, because I want to present all the four columns. value
can be used as X-axis
, word
can be used as y-axis
and the name
can be used as Z-axis
. Then how to use number
here?
May be a graph like this will be helpful, I can represent number
by using color scale in legend
.
Now, my question is, how to generate this plot in R? and is it a right way to present my data?