library(sf)
## Exemplary input Polygon with 2km x 2km:
area <- sf::st_as_sf(sf::st_sfc(
sf::st_polygon(list(cbind(
c(4498482, 4498482, 4499991, 4499991, 4498482),
c(2668272, 2669343, 2669343, 2668272, 2668272)
))),
crs = 3035
))
Grid <- grid_area(area, 200, 1, TRUE)
## Create 5 individuals with 10 wind turbines each.
firstPop <- init_population(grid = Grid[[1]], n = 10, n_start = 5)
Run the code above in your browser using DataLab