partition_lung: Partition the lung

Description Usage Arguments Value

View source: R/partition_lung.R

Description

Partition the lung

Usage

1
2
3
4
5
6
partition_lung(
  img,
  kernel_size = c(30, 30, 30),
  kernel_stride = c(30, 30, 30),
  centroid = TRUE
)

Arguments

img

Lung scan to be partitioned. Can be in 3D matrix or ANTs image file format.

kernel_size

Size of the kernel, in voxel units of width, depth, and height. Must be c(3,3,3) or greater. Default: c(30,30,30)

kernel_stride

Stride (or spacing) between kernels, in voxel units, for width, depth, and height. If kernel_stride = kernel_size, the partitions are non-overlapping. If stride = c(1,1,1), then each voxel is returned.

centroid

Logical. If true, output includes the centroids of each partition.

Value

Matrix of x, y, and z coordinates for each partition


muschellij2/lungct documentation built on July 13, 2020, 2:17 p.m.