I am trying to crop the bioclimatic data from WorldClim.org to get environmental features only for the Australian habitat using the extent()
method. Finally, I plan to combine the bioclimatic data with the occurrence data to perform species distribution modelling.
However, I cannot understand how the xmin, xmax, ymin and ymax spatial coordinate values are provided to the biocli<-stack(crop(bioclimatic,(extent(xmin, xmax, ymin, ymax))))
method.
Best Answer
The extent can be extracted from another object. So if you have, e.g. SpatialPolygons for Australia,
aus
you can doYou can also look at a map and do something like
And you can refine that with trial and error.
Moreover, you can do
With "terra" (the replacement of "raster"), replace
extent
withext
anddrawExtent
withdraw
.