# NOT RUN {
# load required data
data(cat_ls)
# convert data to object of class winmove
cat_ls <- new("winmove", cat_ls)
# aggregate using a rectangular window with dimension 5 for class 3
d <- prop(cat_ls, d = 5, type = "rectangle", lc_class = 3)
# convert data to object of class numeric
cat_ls <- raster::values(cat_ls)
d <- prop(cat_ls, lc_class = 2)
# }
Run the code above in your browser using DataLab