[R] Grouped Histogram (colored)
till.salzgeber at gmail.com
Thu Oct 16 18:42:06 CEST 2008
I'm trying to create a histogram which shows the frequency of variables
within a certain timeframe.
I've been using SPSS before, but I didn't quite like it...
To describe my problem further here are some example variables:
the "event" is actually a string which I recoded using:
data$event_class = as.numeric(as.factor(data$event))
I've recoded them into numerics
and so on...
Now I'd like to create a histogram where X is the time, the color of the
area is the event_class
and Y is defined by the frequency of event_class around some accumulated
In SPSS I used this:
Graphs -> Chart Builder
use some horizontal histogram
put "time" on the x-axis
select "grouping/stacking variables" in the "groups/point id" tab
and then set "Stack: set-color" to event_class
the y-axis will be automatically set to "histogram"
thanks a lot in advance!
View this message in context: http://www.nabble.com/Grouped-Histogram-%28colored%29-tp20015941p20015941.html
Sent from the R help mailing list archive at Nabble.com.
More information about the R-help