I have two variables that I want to compare in a histogram like the one below. For each bin of the histogram the frequency of both variables is shown what makes it easy to compare them.

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You can use the
addparameter tohist(see?hist,?plot.histogram):To find out about the
addparameter I noticed that in?histthe...argument says that these are arguments passed toplot.histogram, andaddis documented in?plot.histogram. Alternatively, one of the examples at the bottom of?histuses theaddparameter.