aggregate_num {groupedHyperframe}R Documentation

Aggregate numeric hypercolumns and/or marks, by Cluster

Description

Aggregate numeric hypercolumns and/or marks by sample clustering.

Usage

aggregate_num(
  X,
  by = stop("must specify `by`"),
  FUN,
  FUN.name = deparse1(substitute(FUN)),
  f_aggr_ = pmean,
  mc.cores = getOption("mc.cores"),
  ...
)

aggregate_quantile(X, ...)

aggregate_kerndens(X, ...)

Arguments

X

a groupedHyperframe, containing either or all of

by

one-sided formula, one-level hierarchy clustering, e.g., ~patient or ~image. Do not use multi-level hierarchy, e.g., ~patient/image

FUN

function to extract information, currently supports functions quantile and kerndens

FUN.name

(optional) character scalar, user-friendly name of FUN

f_aggr_

see function aggregate_by_()

mc.cores

integer scalar, see function mclapply. Default is 1L on Windows, or detectCores on Mac.

...

additional parameters of function FUN

Details

Function aggregate_quantile() is a wrapper of workhorse function aggregate_num() with FUN = quantile.

Function aggregate_kerndens() is a wrapper of workhorse function aggregate_num() with FUN = kerndens.

Value

Function aggregate_num() returns a data.frame, with aggregated information stored in matrix-columns.


[Package groupedHyperframe version 0.2.4 Index]