threshold_dataset {IrisSpatialFeatures} | R Documentation |
This function reads the manually determined thresholds of certain markers (e.g. PD1, PD-L1) and splits selected celltypes into marker+ and marker- celltypes.
threshold_dataset(image_set, marker, marker_name, base = NULL, pheno_name = "Phenotype", remove_blanks = TRUE) ## S4 method for signature 'ImageSet' threshold_dataset(image_set, marker, marker_name, base = NULL, pheno_name = "Phenotype", remove_blanks = TRUE)
image_set |
IrisSpatialFeatures ImageSet object. |
marker |
Name of the marker used in the score file. |
marker_name |
corresponding name, which should be appended at the selected cell types. |
base |
Vector of cell types for which the marker should be used. |
pheno_name |
Name of the phenotype column to be used. (Default from inForm is "Phenotype") |
remove_blanks |
Flag that indicates whether or not not called cells are to be removed. (Default: TRUE) |
IrisSpatialFeatures ImageSet object.
dataset <- read_raw(path=system.file("extdata", package = "IrisSpatialFeatures"), format='Mantra') dataset <- threshold_dataset(dataset, marker='PD-Ligand-1 (Opal 690)', marker_name='PDL1', base=c('SOX10+')) dataset <- threshold_dataset(dataset, marker='PD-1 (Opal 540)', marker_name='PD1', base=c('CD8+','OTHER'))