Skip to content

Instantly share code, notes, and snippets.

@abrarShariar
Last active September 12, 2019 15:51
Show Gist options
  • Save abrarShariar/0f0ba6e8b4a4947c571c58647e712ff8 to your computer and use it in GitHub Desktop.
Save abrarShariar/0f0ba6e8b4a4947c571c58647e712ff8 to your computer and use it in GitHub Desktop.
all_males_surivived <- data.combined[which(data.combined$sex == 'male' & data.combined$survived == 1),]
ggplot(all_males_surivived, aes(x = all_males_surivived$age, fill = factor(all_males_surivived$pclass))) +
geom_bar(width = 0.5) +
xlab("Age") +
ylab("Pclass") +
labs(fill = "Age")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment