Learn R Programming

imageHTS (version 1.22.0)

extractFeatures: Extract features from segmented images.

Description

Extract features from segmented images.

Usage

extractFeatures(x, uname, featurePar, access='cache')

Arguments

x
An imageHTS object.
uname
a character vector, containing the well names to segment. See getUnames for details.
featurePar
a character string, indicating the filename containing the feature extraction parameters.
access
A character string indicating how to access the data. Valid values are local, server and cache, the default. See fileHTS for details.

Value

None.

Details

extractFeatures reads the DCF segmentation parameters file pointed by featurePar. The file must contain the field extractfeatures.method that indicates which core feature extraction function to use. The function takes two arguments: cal, the calibrated image to extract the features from, and seg, a list of two images, cseg and nseg, which contains the cell and nucleus segmentation masks, respectively. The function returns a matrix of features. See getCellFtrsATH for example.

For each well, extractFeatures writes a ftrs segmentation data file that contains the cell features. Use readHTS or collectCellFeatures to get the cell features after extraction.

See Also

getCellFtrsATH, fileHTS, collectCellFeatures

Examples

Run this code
## initialize imageHTS object using the local submorph screen
local = tempdir()
server = system.file('submorph', package='imageHTS')
x = parseImageConf('conf/imageconf.txt', localPath=local, serverURL=server)
x = configure(x, 'conf/description.txt', 'conf/plateconf.txt', 'conf/screenlog.txt')

## segment one well
uname = getUnames(x, content='rluc')[1]
segmentWells(x, uname=uname, segmentationPar='conf/segmentationpar.txt')

## extract features from the well
extractFeatures(x, uname=uname, 'conf/featurepar.txt')

## read the feature file using readHTS
y = readHTS(x, type='ftrs', uname=uname)

## get features using collectCellFeatures
y = collectCellFeatures(x, uname=uname)

Run the code above in your browser using DataLab