I have a question regarding my bean plot and the legend. I cannot find a way to do following things
- change the x-axis labels (from
communication_focused
tocommunication-focused
) - show the y-axis in more fine-grained way (e.g. breaks should be from 0, 25,50,75,100,125...300)
- put the legend outside the plot
- keep the font of the text in legend bigger than what I get now
- mark the
mean
(black solid line in each category) in each category in "red" color
Here is my code:
beanplot(onset_s~ group*meaning, data=mu3,ll = 0.08,
main = "Distribution of movement units", side = "both",
col = list("black", c("grey", "white")),
axes=T, beanlines = "median")
legend("topleft",fill = c("grey", "black"), legend = c("Non-Performers", "Experts"), cex=0.65)
My data set:
tier meaning onset_sgroup
head_face_mu self_focused 0 expert
head_face_mu self_focused 0 expert
head_face_mu context_focused 0 expert
upper_body_mu self_focused 0 expert
upper_body_mu self_focused 0 expert
head_face_mu communication_focused 0 novice
head_face_mu context_focused 0 novice
head_face_mu context_focused 0 novice
upper_body_mu self_focused 0 novice
upper_body_mu self_focused 0 novice
upper_body_mu self_focused 0 novice
head_face_mu self_focused 0.18 novice
lower_body_mu self_focused 0.667 novice
head_face_mu communication_focused 0.69 novice
head_face_mu context_focused 1.139 novice
head_face_mu context_focused 1.301 novice
head_face_mu context_focused 1.32 novice
lower_body_mu self_focused 1.66 novice
head_face_mu context_focused 1.98 novice
lower_body_mu self_focused 2.205 novice
head_face_mu communication_focused 2.297 novice
head_face_mu context_focused 2.349 novice
lower_body_mu self_focused 2.417 novice
upper_body_mu self_focused 2.666 novice
head_face_mu self_focused 2.675 expert
head_face_mu context_focused 3.218 novice
head_face_mu context_focused 3.353 novice
head_face_mu context_focused 3.436 expert
head_face_mu context_focused 3.588 novice
head_face_mu context_focused 3.697 novice
upper_body_mu self_focused 4.006 novice
upper_body_mu context_focused 4.033 novice
upper_body_mu self_focused 4.06 expert
head_face_mu context_focused 4.33 novice
upper_body_mu self_focused 4.332 novice
upper_body_mu self_focused 4.44 novice
head_face_mu context_focused 4.738 novice
lower_body_mu self_focused 5.395 novice
head_face_mu self_focused 5.428 novice
lower_body_mu self_focused 5.926 novice
head_face_mu context_focused 6.283 novice
head_face_mu context_focused 7.002 novice
head_face_mu self_focused 7.031 novice
lower_body_mu self_focused 7.189 novice
upper_body_mu communication_focused 7.45 novice
lower_body_mu self_focused 7.632 expert 1.144
head_face_mu self_focused 7.739 expert 2.159
lower_body_mu self_focused 8.943 novice 9.517
head_face_mu context_focused 9.002 expert 4.608
This is my graph:
Any feedback and comments are more than welcome!
Thank you in advance.