View source: R/plotCarbonsDoubleBonds.R
plotCarbonsDoublebonds | R Documentation |
Creates a heatmap of logfold change of the lipids with carbon length on y-axis and double_bonds on x-axis
plotCarbonsDoublebonds(df)
df |
A dataframe with a log2(FC) column containing log2 fold change values of different lipid species, that has been run through countCarbonsDoubleBonds and getLipidType. |
A ggplot2 heatmap.
data <- tibble( 'feature' = c('AC(6:0)', 'AC(8:1)', 'AC(10:2)', 'Cer(d18:0/16:0)', 'Cer(d18:0/24:1)', 'Cer(d18:1/24:1)', 'DAG(18:0/18:1)', 'DAG(16:1/18:1)', 'DAG(18:2/18:3)'), 'log2(FC)' = c(-2, 0.1, 1.5, 0.5, 0.7, -0.5, 1, 1, 1.2)) to_plot <- data %>% countCarbonsDoublebonds() %>% getLipidType() plot <- to_plot %>% plotCarbonsDoublebonds()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.