# NOT RUN {
# The example below calculates the fractal dimension
# of image/s contained in the folder "source.dir".
# Then, a file named "res.rds" is saved into the "output" folder.
fct2D <- fract2D(dir = "source.dir",
box.size = c(1,2,4,8,16,32,64,128,256,512),
save.dir = "output/",
save.name = "res")
fct2D$D # a data frame with the estimated fractal dimension
fct2D$raw.dat # the raw data from which fractal dimension was calculated
# }
Run the code above in your browser using DataLab