I'm using R, trying to use data I've been given to plot a boxplot. One of the categories is "sex", with (obviously) either "M" or "F". How do I exclude females, so I can use the male data to create a boxplot? I'm new to R, any help would be appreciated!
EDIT: Okay, I managed to make a vector(??) only including male data using newdata<-subset(olympic, sex=="M"). Now how do I do the same but with two subsets of a different category of continous data? Is it similar notation? (E.g. say the category is "hair" with different colours, and I want "blonde" and "ginger")