data(WhiteGrunt2)
str(WhiteGrunt2)
head(WhiteGrunt2)
op <- par(mfrow=c(1,2),pch=19)
plot(tl~age,data=WhiteGrunt2,subset=sex=="female",main="Female")
plot(tl~age,data=WhiteGrunt2,subset=sex=="male",main="Male")
par(op)
Run the code above in your browser using DataLab