chart_data_smooth: Smooth series

View source: R/chart_data_styles.R

chart_data_smoothR Documentation

Smooth series

Description

Specify whether lines should be smoothed, per series. This feature only applies to ms_linechart().

Usage

chart_data_smooth(x, values)

Arguments

x

an ms_chart object.

values

⁠integer(num of series)⁠: a set of smooth values to map data values to. It is a named vector, the values will be matched based on the names. Use 0 to disable smoothing and 1 to enable it. If it contains only one integer it will be associated to all existing series.

Value

An ms_chart object.

See Also

Other Series customization functions: chart_data_fill(), chart_data_line_style(), chart_data_line_width(), chart_data_size(), chart_data_stroke(), chart_data_symbol(), chart_labels_text()

Examples

linec <- ms_linechart(data = iris, x = "Sepal.Length",
  y = "Sepal.Width", group = "Species")
linec <- chart_data_smooth(linec,
  values = c(virginica = 0, versicolor = 0, setosa = 0) )

mschart documentation built on May 17, 2026, 1:09 a.m.