Ecosystems Modeller and Weed Ecologist @Rothamsted
Pronouns: she/her
Working on:
- πΎ Agriculture
- πΏ Ecology
- π₯ Modelling
- πΊοΈ Spatial statistics
Find me online:
- π Homepage
- π’ OrcID
- π Google Scholar
Contact GitHub support about this userβs behavior. Learn more about reporting abuse.
Report abusePronouns: she/her
Working on:
Find me online:
An interactive introduction to modelling using the life-cycle of an agricultural weed as an example.
R
## Unzip all files in a directory (recursive) ----------
UnzipAll <- function(FilePath) {
## Unzip any zip files ----------
# WARNING - Also removes the zip file once it has been unzipped
## IncrementID-----------
# Returns a number that is 1 more than the highest number in the given column
IncrementID <- function(ThisCol) {
if (sum(ThisCol)<1) {
ThisFileID <- 1
# e.g. Find the shannon diversity of the landscape in a radius of 1000m around each point
result <- furrr::future_map(1:nrow(pts), function(i) {
sample_lsm(landscape, y=matrix(pts[i, ],ncol=2),
plot_id = Ptsdf$PtsID[i], size = 1000, what = "lsm_l_shdi", shape = "circle")
})