addClusterVariable: Add discrete/categorical variables

Description Usage Arguments Value

View source: R/add-family.R

Description

These functions allow to join new discrete/categorical variables that can be referred to via the across-argument of many functions.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
addClusterVariable(
  object,
  cluster_df,
  cluster_name,
  phase = "first_tmt",
  overwrite = FALSE,
  verbose = TRUE
)

addGroupingVariable(object, input_df, variable_name, phase = "first_tmt")

Arguments

object

A valid cell tracer object.

cluster_df

A data.frame that contains at least two variables:

cell_id

Character. The cells ids that are used to join the cluster variable unambiguously

cluster_name

Character or factor. The cluster variable that is to be joined.

cluster_name, variable_name

Character value. The name of the variable that is to be joined.

phase

Character value. Refers to the phase of the experiment. Valid inputs are:

'before_tmt'

Uses the data that refers to the time before the treatment.

'first_tmt'

Uses the data that refers tot the time after the treatment.

Note: This argument is ignored if the experiment set up did not include any treatment or the treatment started right from the beginning.

input_df

A data.frame that contains at least two variables:

cell_id

Character. The cells ids that are used to join the cluster variable unambiguously

variable__name

Character or factor. The discrete variable that is to be joined.

Value

An updated cell tracer object that contains the data added.


kueckelj/celltracer documentation built on June 2, 2021, 6:37 a.m.