View source: R/main-alt-helpers.R
RestructureDF | R Documentation |
RestructureDF
generates the list of dataframes containing single-cell data
where each consecutive member is a dataframe from a different timepoint, from a single
dataframe where a column designates the timepoints and if relevant, the conditions, of
each individual cell. This function is a pre-processing step before starting a FLOWMAPR
analysis using FLOWMAPfromDF as it only accepts single-cell data in a certain format.
RestructureDF(df, time.col.label = "Time", condition.col.label = NULL)
df |
a single dataframe containing all single-cell data from all treatments and conditions (if relevant) to be restructured |
time.col.label |
Character specifying the channel name that should
be used to find the timepoint label for each cell, default is set to |
condition.col.label |
Character specifying the channel name that should
be used to find the condition label for each cell, default is set to |
a list of dataframes containing the single-cell data or if condition.col.label
is provided (not NULL
), a list of lists containing dataframes of single-cell data
## Not run: df <- read.csv(file = system.file("extdata/csv/single-cell-data.csv",package = "FLOWMAPR"), header = TRUE, sep = ",")
## Not run: RestructureDF(df, time.col.label = "Timepoint", condition.col.label = "Treatment")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.