Skip to contents

Get CBEA scores for a given matrix and a vector of column indices

Usage

get_raw_score(X, idx)

Arguments

X

(Matrix). OTU table of matrix format where taxa are columns and samples are rows

idx

(Integer vector). Vector of integers indicating the column ids of taxa in a set

Value

A matrix of size n by 1 where nis the total number of samples

Examples

data(hmp_gingival)
seq <- hmp_gingival$data
seq_matrix <- SummarizedExperiment::assays(seq)[[1]]
seq_matrix <- t(seq_matrix) + 1
rand_set <- sample(seq_len(ncol(seq_matrix)), size = 10)
scores <- get_raw_score(X = seq_matrix, idx = rand_set)