R 可以从特定区域的 google 地图中获取坐标吗?

Can R get coordinates from google maps for specific area?

我试着描述我的问题。 这里 google 地图 https://www.google.ru/maps/@9.1424367,78.5355178,114652m/data=!3m1!1e3 (印度区Pudukkotan) 假设我需要在这个领域工作

我该怎么办! 首先 放大卫星图像

主要任务获取绿地(播种地)和棕地(非播种地)的坐标

有什么方法可以将坐标绿色和棕色字段转换为 data.frame(1-绿色,0-棕色)? 或者是否有任何 CV 方法可以识别选定地区的绿色和棕色田地?

不确定这是否能解决您的问题...但这是第一种方法;在您的图像中搜索特定颜色(具有公差)..

library(raster)

#load inmage you posted in question
myimage.jpg <- tempfile()
download.file("https://i.stack.imgur.com/4WCt2.jpg",
              myimage.jpg, 
              mode = "wb")
#load image to raster
myimage.raster <- raster::stack(myimage.jpg)
names(myimage.raster) <- c("r","g","b")
#what it looks like
plotRGB(myimage.raster)

#select some forest
myimage.forest <- myimage.raster
myimage.forest$forest <- 0
#values of greenish stuff, play around here
red       <- 100 
green     <- 90
blue      <- 60
tolerance <- 50  #this is your firs vairiable to tamper with...

#let's find some forest
myimage.forest$forest[ myimage.forest$r > (red * (100 - tolerance) / 100) & 
                         myimage.forest$r < (red * (100 + tolerance) / 100) &
                         myimage.forest$g > (green * (100 - tolerance) / 100) & 
                         myimage.forest$g < (green * (100 + tolerance) / 100) &
                         myimage.forest$b > (blue * (100 - tolerance) / 100) & 
                         myimage.forest$b < (blue * (100 + tolerance) / 100)] <- 1
#what does this look like?
plot(myimage.forest$forest)