add_annotation: Add information to an annotation data structure

Description Usage Arguments Value Examples

View source: R/plot_functions.R

Description

Function to iteratively add information to an annotation data structure as needed for HeatmapAnnotation and especially for annotation_exposures_barplot

Usage

1
2
3
4
5
6
7
add_annotation(
  in_annotation_col,
  in_annotation_df,
  in_attribution_vector,
  in_colour_vector,
  in_name
)

Arguments

in_annotation_col

List, every element of which refers to one layer of annotation List elements are structures corresponding to named colour vectors

in_annotation_df

Data frame, every column of which corresponds to a layer of annotation. It has as many rows as there are samples, every entry in a row corresponding to the attribute the samples has for the corresponding layer of annotation.The factor levels of a column of in_annotation_df correspond to the names of the corresponding element in in_annotation_col

in_attribution_vector

A vector which is going to be cbinded to in_annotatiin_df, carrying the annotation information of the new layer to be added

in_colour_vector

Named vector of colours to be attributed to the new annotation

in_name

Name of the new layer of annotation

Value

A list with entries

Examples

1

YAPSA documentation built on Nov. 8, 2020, 4:59 p.m.