[R] Bar Graph

Keniajin Wambui kiangati at gmail.com
Mon Nov 11 16:02:19 CET 2013

I am using R 3.0.2 on a 64 bit machine

I have a data set from 1989-2002. The data has four variables
serialno, date, admission ward, temperature and bcg scar.

serialno admin_ward date_admn bcg_scar temp_axilla yr
70162    Ward2         11-Oct-89       y           38.9 1989
70163     Ward1        11-Oct-91       y             37.2 1991
70164     Ward2       11-Oct-92        n               37.3 1992
70165     Ward1        11-Oct-93        y                38.9 1993
70166     Ward1       11-Oct-94          y              37.7 1994
70167      Ward1       11-Oct-95          y              40 1995

I want to do a bar graph of total data (serialno) vs *(data of one of
the variables) to show the available data vs total data over the years

i am using

gplot(dta, aes(temp_axilla, fill=admin_ward)) + geom_bar() +
  facet_grid(. ~ yr, scales = "free",margins=F) + geom_histogram(binwidth=300)

But can include the serialno which shows the data. how can I achieve this

Mega Six Solutions
Web Designer and Research Consultant
Kennedy Mwai

More information about the R-help mailing list