mennodejong1986 / SambaR

SambaR: Snp datA Management and Basic Analyses in R
MIT License
24 stars 6 forks source link

mapping issues #32

Open gspellman opened 3 months ago

gspellman commented 3 months ago

I am trying to use the map function and get the following error. I have Rworldmap installed which uses the function getMap. I would appreciate any help

Plotting location of samples using R package Rworldmap... Flags 'mygeodf' and 'mygeofile' set to NULL (default). Assuming to find within inds dataframe columns called 'longitude' and 'latitude'. Matrix with geographical coordinates has been stored under the name 'mysambar$geocoord'. Error in getMap(resolution = "low") : could not find function "getMap"

mennodejong1986 commented 3 months ago

The function getMap() is part of the R package Rworldmap, so it seems that for some reason this package either has not been installed yet or alternatively not loaded yet.

To load, use this command:

library(rworldmap)

If the above gives an error, you first need to install (and afterwards retry loading):

install.packages("rworldmap")

Hope this solves the problem!