Skip to content

Error while plotting: missing values in coordinates not allowed #29

@CNLove-260

Description

@CNLove-260

Thank you for the great new package. I seem to be having some issues while attempting to run the commands with my own data however.

mapmixture(admixture1, coordinates, crs = 3035)

Error in st_as_sf.data.frame(x = data, coords = c(3, 2)) :
missing values in coordinates not allowed

I saw that there was a similar issue in another comment, with the issue stemming from a CRS error. However, I have not yet tried altering the base map, so am unsure where the issue might be stemming from?

My data look something like:

head(coordinates)

Site lat lon
1 ASD 72769 30524
2 ZXC 66911 33627
3 BNM 92405 31533

head(admixture)

Site Ind Cluster1 Cluster2 Cluster3 Cluster4 Cluster5
5 ASD 11 0.473244 1e-05 1e-05 0.000010 0.526726
6 ASD 17 0.514554 1e-05 1e-05 0.000010 0.485416
7 ASD 18 0.441918 1e-05 1e-05 0.028100 0.529962
8 ASD 19 0.477872 1e-05 1e-05 0.000010 0.522098
9 ASD 35 0.474079 1e-05 1e-05 0.000010 0.525891

Thanks!

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions