Skip to contents

Generates a square demo raster::brick object with options to set the size (on disk) and number of layers.

Usage

demo_stack_rasterbrick(size = 50, layers = 5)

Arguments

size

[integer(1)]
Size of raster stack in megabyte (disk space).

layers

[integer(1)]
Number of layers.

Examples

if (mlr3misc::require_namespaces("raster", quietly = TRUE)) {
  demo_stack_rasterbrick(size = 5, layers = 2)
}
#> class      : RasterBrick 
#> dimensions : 790, 790, 624100, 2  (nrow, ncol, ncell, nlayers)
#> resolution : 0.001265823, 0.001265823  (x, y)
#> extent     : 0, 1, 0, 1  (xmin, xmax, ymin, ymax)
#> crs        : NA 
#> source     : memory
#> names      :      x_1,        y 
#> min values : -4.39397,  0.00000 
#> max values : 5.499034, 1.000000 
#>