The standard deviation of the noise function convolved with array values to induce blur in raster data.
Arguments
- range
A two-element vector holding the defaults for the smallest and largest possible values, respectively. If a transformation is specified, these values should be in the transformed units.
- trans
A
transobject from thescalespackage, such asscales::transform_log10()orscales::transform_reciprocal(). If not provided, the default is used which matches the units used inrange. If no transformation,NULL.
Details
The gaussian blur step deploys blur(). See there for definitions
and references.
get_blur_range() varies the parameter logarithmically from 0 to an order
of magnitude greater than the blur() default.
Examples
img_dat <- data.frame(img = I(list(volcano)))
(blur_man <- blur_sigmas(range = c(0, 3)))
#> Gaussian Blur std. dev.s (quantitative)
#> Transformer: log1p [-1, Inf]
#> Range (transformed scale): [0, 3]
grid_regular(blur_man)
#> # A tibble: 3 × 1
#> blur_sigmas
#> <dbl>
#> 1 0
#> 2 3.48
#> 3 19.1
(blur_fin <- blur_sigmas() %>% get_blur_range(x = img_dat))
#> Gaussian Blur std. dev.s (quantitative)
#> Transformer: log1p [-1, Inf]
#> Range (transformed scale): [1.47, 3.47]
grid_regular(blur_fin)
#> # A tibble: 3 × 1
#> blur_sigmas
#> <dbl>
#> 1 3.37
#> 2 10.9
#> 3 31.3