I'm quite new to R - I want to colour code my points according to qualitative variable called "Fraction" which I have achieved, however, simultaneously I also want to change the shape of the points based on a different qualitative variable called "Landuse"
Currently I have:
fviz_pca_biplot(SXR_PCA,
label="var",
habillage = SXR_input$Fraction,
pointshape = 19,
col.var = "black",
addEllipses = TRUE, ellipse.type = "norm",
legend.title = "Fraction",
mean.point = FALSE,
ggtheme = theme_classic()) +
ggtitle("")+
scale_color_manual(values=c("#782ED1","#D1782E","#2ED178"))
Ive been able to change shape based on the "Fraction" variable, and have been able to change all points to the same shape, but struggling to find anything that enables me to change shape based on a different variable
I think you need to add your own
geom_point()in order to change the shapes, e.g.Created on 2024-02-21 with reprex v2.1.0