Polyfunctionnality_piechart: Piecharts for polyfunctionnality of ICS data The complete...

View source: R/ICS-Polyfunctionnality_piechart.R

Polyfunctionnality_piechartR Documentation

Piecharts for polyfunctionnality of ICS data The complete cytokines must have this type of format : IFN-IL2+MIP1b-TNF+ in CD4

Description

Piecharts for polyfunctionnality of ICS data

The complete cytokines must have this type of format : IFN-IL2+MIP1b-TNF+ in CD4

Usage

Polyfunctionnality_piechart(
  data_ICS,
  list_cytokines,
  ID_name,
  group_var,
  group_value,
  Timepoint_var,
  Timepoint_value,
  Stim_var,
  Stim_value,
  cellPop_type,
  group_cyto = NULL,
  title_piechart = NULL,
  leg_piechart = TRUE,
  pie_col = NULL,
  ring_col = NULL
)

Arguments

data_ICS

Dataset to yse for plot.

list_cytokines

a vector with the cytokines avalaible in data_ICS (in order of appareance in boolean cytokines)

ID_name

a character to give the colname of subject ID variable in data_ICS

group_var

a character to give the colname of group variable in data_ICS

group_value

a character to select one factor of group_var

Timepoint_var

a character to give the colname of Time point in data_ICS

Timepoint_value

a character to select one factor of Timepoint_var

Stim_var

a character to give the colname of stimulation variable in data_ICS

Stim_value

a character if you want to focus on one stimulation (in case of you have several stimulations in data_ICS)

cellPop_type

a character if you have differents populations for your cytokines. It must be present in the column names with cytokines.

group_cyto

a vector of numerics if you want to combine two numbers of cytokines (i.e. "c(2,3)" if you want to have a category with "2 and 3" cytokines together). Default is NULL.

title_piechart

a character with your title or NULL if you don't want a title.

leg_piechart

a logical value. If TRUE, the legend is shown. Default is TRUE.

pie_col

a vector of colors for slices. Default is NULL then colors of grey.colors function will be use.

ring_col

a vector of colors for rings. Default is NULL then colors of rainbow function will be use.

Value

a pie object

Author(s)

Mélanie Huchon (adapted to Mélany Durand codes)

Examples

Polyfunctionnality_piechart(data_ICS = ICS_data, 
list_cytokines = c("IFN", "IL2", "MIP1b", "TNF"), ID_name = "ID", group_var = "Arm", 
group_value = "Arm1",  Timepoint_var = "TP", Timepoint_value = "TP1", Stim_var = "Stim", 
Stim_value = "BackgroundSubstracted", cellPop_type = "CD4", title_piechart = "Polyfunctionnality", 
leg_piechart = TRUE)

sistm/sistmr documentation built on March 8, 2024, 3:05 a.m.