I'm trying to replicate the graph similar to the following (originally found HERE)
It's conceptually simple, but I'm a bit stumped as to how to do it in R.
To summarize: I want to generate histograms of behavioral frequency over the 24 hours of the day (24-level factor variable) by each day of the week. Then, I want to stack these histograms on top of each other so that the distribution of behavior over the hour of day can easily be compared (again, see example).
For example, my data might look like this:
weekday hour count Tuesday 15 553 Monday 1 53 Monday 10 539 Monday 15 629 Tuesday 9 281 Saturday 4 11 Monday 3 20 Sunday 3 10 Sunday 7 2 Sunday 2 17
How do I go about implementing the graph in the link above? I'm terrible with ggplot
, but have a sense it's the likely solution. Thanks!