R package with data sets used in the material on the https://rspatial.org website to teach spatial data analysis with R.
You can install the package like this
remotes::install_github("rspatial/rspatial")
rspatial website using terra
License: Other
R package with data sets used in the material on the https://rspatial.org website to teach spatial data analysis with R.
You can install the package like this
remotes::install_github("rspatial/rspatial")
The section https://rspatial.org/terra/spatial/8-rastermanip.html#spatial-configuration talks about the functions patches
, boundaries
and area
-- and is then followed by an example for zonal
(that doesn't use any of the above), without any comment.
The text in 2_sdm_occdata.rmd still references wrld_simpl
in three places, but the code has been updated to use geodata::world
.
You also have one reference to gridSample
, but don't mention dismo
anymore. I think this is also an outdated line:
Thanks for maintaining this great resource!
Reading through https://rspatial.org/terra/spatial/8-rastermanip.html I not only came across the SpatRaster
class, but apparently also raster
and Raster
. Sometimes this confused me. Especially I didn't know if raster
and Raster
are the same or not.
Examples:
Many generic functions that allow for simple and elegant raster algebra have been implemented for
Raster
objects [...] In these functions you can mixraster
objects with numbers, as long as the first argument is araster
object. [...] Create an emptySpatRaster
and assign values to cells.
The origin of a
Raster
object is the point closest to (0, 0) that you could get if you moved from a corner of aSpatRaster
toward that point in steps of the x and y resolution.
The crop function lets you take a geographic subset of a larger
raster
object. You can crop aSpatRaster
by providing an extent object or another spatial object from which an extent can be extracted (objects from classes deriving fromRaster
and from Spatial in the sp package).
Could you clarify the connection between these somewhere? It may be obvious for you developers, but it isn't for newbies.
Sorry if this already exists, but I didn't come across it in https://rspatial.org/terra/spatial/2-spatialdata.html nor https://rspatial.org/terra/spatial/4-rasterdata.html.
Hello,
Terra documentation seems to falsely point to clump
(a raster
method) when it should be patches
. I assume this is an error?
Many thanks for the maintenance of this resource.
I found the following in your (wonderful!) online manual:
If I'm not mistaken, this accomplishes the same thing as:
nc <- rasterize(crime, r, fun = length, background=0)
Although perhaps the more complex form is useful as a clue for how to use arbitrary functions in rasterize
? If that's your intent, please ignore this issue!
Thanks again for all your work building and maintaining these tools!
typo in description of repository: "in stead". Not sure I can open a pull request.
Hi, I have tried to download the data from https://rspatial.org/terra/rs/1-introduction.html#data using:
dir.create("data", showWarnings = FALSE)
if (!file.exists("data/rs/samples.rds")) {
download.file("https://biogeo.ucdavis.edu/data/rspatial/rs.zip", dest = "data/rs.zip")
unzip("data/rs.zip", exdir="data")
}
but get this error:
trying URL 'https://biogeo.ucdavis.edu/data/rspatial/rs.zip'
Content type 'application/zip' length 187858667 bytes (179.2 MB)
downloaded 132.9 MB
Error in download.file("https://biogeo.ucdavis.edu/data/rspatial/rs.zip", :
download from 'https://biogeo.ucdavis.edu/data/rspatial/rs.zip' failed
In addition: Warning messages:
1: In download.file("https://biogeo.ucdavis.edu/data/rspatial/rs.zip", :
downloaded length 139395072 != reported length 187858667
2: In download.file("https://biogeo.ucdavis.edu/data/rspatial/rs.zip", :
URL 'https://data.biogeo.ucdavis.edu/data/rspatial/rs.zip': Timeout of 60 seconds was reached
Unzipping the file does not work:
> unzip("data/rs.zip", exdir="data")
Warning message:
In unzip("data/rs.zip", exdir = "data") :
error 1 in extracting from zip file
Same when using the terminal:
$ unzip rs.zip
Archive: rs.zip
End-of-central-directory signature not found. Either this file is not
a zipfile, or it constitutes one disk of a multi-part archive. In the
latter case the central directory and zipfile comment will be found on
the last disk(s) of this archive.
unzip: cannot find zipfile directory in one of rs.zip or
rs.zip.zip, and cannot find rs.zip.ZIP, period.
In https://rspatial.org/terra/spatial/7-vectmanip.html#records
Where it says: "See ?select for interactively"
Might be '?sel', instead. (although '?sel' doens't correctly show any help page). Anyway, sel(df) works fine selecting geometries in a plot.
My R version 4.0.4, terra_1.7-3
PS. Sorry I forgot to ask if it is useful or appropiate to inform about typos here as issues.
PPS. Here is another dummy typo: "For this example, we first we get the name of an example file [...]" at https://rspatial.org/terra/spatial/8-rastermanip.html#creating-spatraster-objects.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.