Re: [R] Stacked Histogram, multiple lines for dates of news stories?

2010-06-29 Thread Jim Lemon
On 06/29/2010 01:04 AM, Simon Kiss wrote: Dear colleagues, I have extracted the dates of several news stories from a newspaper data base to chart coverage trends of an issue over time. They are in a data frame that looks just like one generated by the reproducible code below. I can already genera

Re: [R] Stacked Histogram, multiple lines for dates of news stories?

2010-06-28 Thread Hadley Wickham
Hi Simon, Here are two ways to do that with ggplot: qplot(test2, data = test_df, geom = "freqpoly", colour = test, binwidth = 30, drop = F) qplot(test2, data = test_df, geom = "bar", fill = test, binwidth = 30) binwidth is in days. If you want to bin by other intervals (like months), I'd recomm

[R] Stacked Histogram, multiple lines for dates of news stories?

2010-06-28 Thread Simon Kiss
Dear colleagues, I have extracted the dates of several news stories from a newspaper data base to chart coverage trends of an issue over time. They are in a data frame that looks just like one generated by the reproducible code below. I can already generate a histogram of the dates with vari