From edbebb19ee536e7bc90e34c179798c3ce2bf1387 Mon Sep 17 00:00:00 2001 From: Anshul Singhvi Date: Sun, 6 Oct 2024 07:43:03 -0700 Subject: [PATCH] Update README.md to use GeometryOps Leads to a simpler API for the buffer ;) --- README.md | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 96ed509..653bb2c 100644 --- a/README.md +++ b/README.md @@ -15,6 +15,7 @@ The following example models the distribution of _Anopheles nili_, a malaria vec We'll use several other packages in addition to SpeciesDistributionModels ```julia using SpeciesDistributionModels, Rasters, RasterDataSources, GBIF2, LibGEOS, ArchGDAL, StatsBase +import GeometryOps as GO import SpeciesDistributionModels as SDM ``` @@ -28,7 +29,7 @@ presence_points = unique(occurrences.geometry) The region of interest will be defined by a convex hull around our presence points, buffered by 5 degrees. ```julia -roi = buffer(convexhull(MultiPoint(LibGEOS.to_geos.(presence_points))), 5) +roi = GO.buffer(GO.convex_hull(presence_points), 5) ``` Now we'll load bioclimatic variables from WorldClim, using `RasterDataSources` and `Rasters`. @@ -133,4 +134,4 @@ parent: 24.3333 0.00357797 0.00445221 0.00637058 0.00660174 0.00547219 24.5 0.00610894 0.00443861 0.00616782 0.00583453 0.00602396 24.6667 0.00440761 0.00360355 0.00649026 0.00615647 0.00665752 -``` \ No newline at end of file +```