Learn R Programming

bioimagetools (version 1.1.8)

segment.outside: Segmentation of the background of 3D images based on automatic threshold

Description

Segmentation of the background of 3D images. Starting from the borders of the image, the algorithm tries to find the edges of an object in the middle of the image. From this, a threshold for the edge is defined automatically. The function then return the a logical array representing voxel inside the object.

Usage

segment.outside(img, blobsize = 1)

Arguments

img

is a 3d array representing an image.

blobsize

is an integer, representing the minimal diameter for bridges from the outside. E.g., a blobsize=3 allows for holes of size 2*(blobsize-1)=4 in the edge of the object.

Value

A binary 3D array: 1 outside the object, 0 inside the object.

Examples

Run this code
# NOT RUN {
kringel <- readTIF(system.file("extdata","kringel.tif",package="bioimagetools"))
out <- segment.outside(kringel)
img(out, z=1)
# }

Run the code above in your browser using DataLab