When used on pathological data (like when there is only one patch size), patchdistr_spews will use the data without trouble, but plotting will return a cryptic error:
E.g.:
a <- matrix(FALSE, ncol = 10, nrow = 10)
a[1,1] <- TRUE
a <- list(a, a, a, a)
p <- patchdistr_spews(a)
plot(p)
Error in sum(type_freqs) : invalid 'type' (list) of argument
There is a probably a better way to handle this (e.g.. by producing a warning in patchdistr_spews or an error in its plot method).
When used on pathological data (like when there is only one patch size), patchdistr_spews will use the data without trouble, but plotting will return a cryptic error:
E.g.:
There is a probably a better way to handle this (e.g.. by producing a warning in patchdistr_spews or an error in its plot method).