barplot_internal: Bar plot for dataframe

View source: R/visualization.R

barplot_internalR Documentation

Bar plot for dataframe

Description

Bar plot for dataframe

Usage

barplot_internal(
  df,
  x = "cellType",
  y = "value",
  fill = "condition",
  legend.title = NULL,
  width = 0.6,
  title.name = NULL,
  xlabel = NULL,
  ylabel = NULL,
  color.use = NULL,
  remove.xtick = FALSE,
  stat.add = FALSE,
  stat.method = "wilcox.test",
  percent.y = FALSE,
  label.x = 1.5,
  show.legend = TRUE,
  x.lab.rot = FALSE,
  size.text = 10
)

Arguments

df

a dataframe

x

Name of one column to show on the x-axis

y

Name of one column to show on the y-axis

fill

Name of one column to compare the values

legend.title

Name of legend

width

bar width

title.name

Name of the main title

xlabel

Name of x label

ylabel

Name of y label

color.use

defining the color of bar plot;

remove.xtick

whether remove x tick

stat.add

whether adding statistical test

stat.method, label.x

parameters for ggpubr::stat_compare_means

percent.y

whether showing y-values as percentage

show.legend

Whether show the legend

x.lab.rot

Whether rorate the xtick labels

size.text

font size

Value

ggplot2 object


sqjin/CellChat documentation built on Nov. 10, 2023, 4:29 a.m.