cKmeansDownsampleSqrt: Wrapper for constrained K-means on data subsampled to the...

View source: R/cKmeansDownsampleSqrt.R

cKmeansDownsampleSqrtR Documentation

Wrapper for constrained K-means on data subsampled to the square root of the number of observations in each cohort.

Description

This function is a wrapper for the constrained Kmeans algorithm using lcvqe() from the conclust package. This function will subset each cohort down to that with the smallest number of observations.This function is not meant to be run individually, but as a 'clustFunc' argument for running K2tax().

Usage

cKmeansDownsampleSqrt(labels, features, K2res)

Arguments

labels

Vector of cohort values

features

List of features (genes) to include

K2res

A K2 class object.

Value

A character string of concatenated 1's and 2's pertaining to the cohort assignments.

References

\insertRef

reed_2020K2Taxonomer \insertRefcKmK2Taxonomer


montilab/K2Taxonomer documentation built on April 5, 2025, 3:58 a.m.