apexcharter/man/ax_dataLabels.Rd

58 lines
1.3 KiB
Plaintext
Raw Normal View History

2018-07-31 22:56:51 +02:00
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/apex-utils.R
\name{ax_dataLabels}
\alias{ax_dataLabels}
\title{Labels on data}
\usage{
2019-11-26 10:17:42 +01:00
ax_dataLabels(
ax,
enabled = NULL,
textAnchor = NULL,
offsetX = NULL,
offsetY = NULL,
style = NULL,
dropShadow = NULL,
formatter = NULL,
...
)
2018-07-31 22:56:51 +02:00
}
\arguments{
\item{ax}{An \code{\link[=apexchart]{apexchart()}} \code{htmlwidget} object.}
2018-07-31 22:56:51 +02:00
2018-09-03 23:52:53 +02:00
\item{enabled}{To determine whether to show dataLabels or not.}
2018-07-31 22:56:51 +02:00
2020-02-15 13:07:05 +01:00
\item{textAnchor}{The alignment of text relative to dataLabel's drawing position.
2018-09-03 23:52:53 +02:00
Accepted values \code{"start"}, \code{"middle"} or \code{"end"}.}
2018-07-31 22:56:51 +02:00
2018-09-03 23:52:53 +02:00
\item{offsetX}{Sets the left offset for dataLabels.}
2018-07-31 22:56:51 +02:00
2018-09-03 23:52:53 +02:00
\item{offsetY}{Sets the top offset for dataLabels.}
2018-07-31 22:56:51 +02:00
2018-09-03 23:52:53 +02:00
\item{style}{A list of parameters.}
2018-07-31 22:56:51 +02:00
2018-09-03 23:52:53 +02:00
\item{dropShadow}{A list of parameters.}
\item{formatter}{The formatter function takes in a single value and allows you to format the value before displaying}
2018-07-31 22:56:51 +02:00
\item{...}{Additional parameters.}
}
\value{
An \code{\link[=apexchart]{apexchart()}} \code{htmlwidget} object.
2018-07-31 22:56:51 +02:00
}
\description{
Labels on data
}
2018-09-03 23:52:53 +02:00
\note{
See \url{https://apexcharts.com/docs/options/datalabels/}
}
2019-06-24 15:18:38 +02:00
\examples{
data("diamonds", package = "ggplot2")
# Add data labels
apex(
2021-01-15 10:53:51 +01:00
data = diamonds,
mapping = aes(x = cut)
2019-06-24 15:18:38 +02:00
) \%>\%
ax_dataLabels(enabled = TRUE)
}