here is my dataframe
data.frame(Subtype = c("OPC", "Hypopharynx", "Larynx"),
alive = c(88, 22, 100),
dead = c(12, 55, 17),
uncertain = c(10, 2, 2),
total = c(186, 46, 202)
I've loaded the ggplot2 package. what I want is something quite simple but struggling to get it.
I want the Subtype variable (i.e.OPC, Hypopharynx, Larynx) as my 'X' with the number of patients (i.e. Total) in the 'Y' axis displayed in the form of a BarChat
I've tried the following code
ggplot(data = tata3, aes(x=Subtype, y=total)) + geom_histogram()
and also
ggplot(data = tata3, aes(x=Subtype, y=total)) + geom_bar()
to no Avail. Can someone please help? thanks