subset levels for plot with subgroups

Hello, I'm a beginner in R so this is probably a very basic question hope you could help me.

I would like to make the same plot but instead of using all "specie" levels just with some of them, for example the first four ("En", "FC","NF" and "NL").

Code:

ggplot(data= TF_IGcurve, aes (x=irradiance, y=growth, colour=specie)) +geom_point(size=2,shape=21,fill="black")+geom_line(linetype=1, size=1)+labs(x="Irradiance",y="Growth rate")

Thank you!! :grinning:

Hi !

Maybe something like this :

ggplot(data = filter(TF_IGcurve, specie %in% c("En", "FC", "NF", "NL")) ...

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.