Skip to contents

Number of ROIs in a layer

Usage

sg_roi_layer_n(layer, call = rlang::caller_env())

Arguments

layer

An sg_roi_layer.

call

The calling environment, for error reporting.

Value

An integer scalar.

Examples

lyr <- sg_roi_layer_add(sg_roi_layer("tissue"),
                        sg_roi_rect(0, 0, 4, 4, label = "tissue"))
sg_roi_layer_n(lyr)
#> [1] 1