morpho {RGeoS} | R Documentation |
Perform morphological operations on a variable defined on a Grid
morpho(dbin, vmin = NA, vmax = NA, oper = "thresh", option = 0, radius = 1, niter = 1, radix = NA, modify.target = TRUE)
dbin |
The |
vmin |
Minimum (inclusive) threshold for the grain definition |
vmax |
Maximum (exclusive) threshold for the grain definition |
oper |
Name of the morphological operation:
|
option |
Type of structuring element or connectivity:
|
radius |
Radius of the structuring element in 3-D. Only used for 'erode', 'dilate', 'open', 'close' and 'dist' operations |
niter |
Number of times the morphological operation is iterated. This argument is not used for the 'thresh', 'cc' and 'dist' operations |
radix |
Radix of the name given to the variable storing the result in the Db. |
modify.target |
When TRUE, the result is set as new target variable in the Db. |
The Db where the following variable has been added:
- the output image (converted into double) for 'thresh', 'erode', 'dilate', 'open', 'close' and 'dist' operations
- the output variable where each pixel is set to FFFF (for pore) or for the rank of the connected component (sorted by decreasing size)