clipmask-class: Class holding info for the clipper

Description Value Slots See Also Examples

Description

The filters we used to support our samples under the uFTIR microscope are round. This means that a cube might not be the best representation of our data, as they have noisy borders that might be missinterpreted by the program. Then, I implemented a clipper function to clip objects of class SAM or Smooth (even an S3 matrix) before summarizing them. Although this can be done step by step, you can also create a clip-mask for the summary_sam function to clip them for you. To crate this clip-mask, you can call the function toClip which returns an object of this class.

The class has yet another use. Since the samples are placed under the microscope by hand, the cropping area is not always the same and (usually) it has to be adjusted. To have a visual aid, you can use the function toClip, to then plot a SAM or Smooth and overlay the croppling circle by calling polygon and the xycoords slot of an object of this class (returned by toClip). Using that process you can test manually different center points and radius for the clipping circle.

Value

An S4 object of class "clipmask" to be used (internally) by the clipper function.

Slots

xycoords

polygon (circle) coodinates to plot. matrix with two columns (x,y).

rad

cicle radius. integer.

centre

circle centre. Numeric vector of two elements (x,y).

See Also

toClip clipper

Examples

1

uFTIR documentation built on Oct. 25, 2021, 9:08 a.m.