I am trying to conduct a RDA analysis, and to do so I had to create a plot with my SNPs (the points on the scatterplot). I assigned colours to my points, but once I plotted them, they were not filled and instead were white circles outlined in gray. Attached is my code, and attached is the image of what I got, and an image of what I want it to look like. Also attached is an image of a smaller dataset to make it easier to see what I'm doing! Thank you in advance!
#gen1 Dataset
POP L0001 L0002 L0003
<chr> <dbl> <dbl> <dbl>
1 AK 0 1 0
2 NU -1 -1 -1
3 GR 1 0 0
4 LB 0 1 0
5 NF 1 0 0
6 ST 0 0 0
7 NS -1 2 0
8 NB 1 2 0
9 ME 0 1 0
10 IC 0 0 0
11 FI 0 0 0
#env1 dataset
POP CHLa.max CHLa.min CHLa.avg
<chr> <dbl> <dbl> <dbl>
1 AK 2.07 0.0623 0.780
2 NU 0.943 0.0697 0.245
3 GR 2.03 0.0494 0.453
4 LB 1.55 0.263 0.678
5 NF 1.63 0.190 0.698
6 ST 2.40 1.17 1.74
7 NS 1.14 0.0708 0.447
8 NB 1.79 0.231 0.900
9 ME 1.69 0.131 0.711
10 IC 2.28 0.147 0.892
11 FI 0.554 0.0569 0.207
#Specify columns
gen1<-gen1[2:4]
#Specify predictors
pred1<-subset(env1[,1])
#Conduct RDA
BLGU.rda <- rda(gen1 ~ ., data=pred1, scale=T)
BLGU.rda
#Define Populations
levels(env1[["POP"]]) <- c("AK", "NU", "GR", "LB", "NF", "ST", "NS", "NB", "ME", "IC", "FI")
#Give Populations Callback Name
eco1 <- env1[["POP"]]
#Assign Colours
bg <- c("#fa8a6b", "#5d7142", "#010c22", "#61cd9e", "#7110b6", "#15c4df", "#892f74", "#0615f3", "#b6faea", "#e402b1", "#ad4833")
#Plot RDA
plot(BLGU.rda, type="n", scaling=2)
#Plot populations
points(BLGU.rda, display="sites", pch=21, cex=1.3, col="gray32", scaling=2, bg=bg[eco])
Scatter Plot of RDA (SNPs vs Environmental Predictors
Scatter Plot of what I want my data to look like