Area
The Area Chart
An area chart displays quantitative data graphically, with the area between the data line and the x-axis filled with color or pattern. This filled area represents volume or quantity, making it a useful tool for visualizing the magnitude or cumulative value of data over a continuous scale, such as time.
The Method To Use
The method is s.plt.area()
It must contain the following parameters:
x: str
order: int
data: Union[str, DataFrame, List[Dict]]
Accepts these parameters as optional:
y: Optional[List[str]]
x_axis_name: Optional[str]
y_axis_name: Optional[str]
title: Optional[str]
rows_size: Optional[int]
cols_size: Optional[int]
padding: Optional[List[int]]
show_values: Optional[List[str]]
option_modifications: Optional[Dict]
variant: Optional[str]
Examples
Suppose you have data points representing accumulated values over days. Here's how you can plot an area chart:
data = [
{'date': dt.date(2021, 1, 1), 'x': 5, 'y': 3},
{'date': dt.date(2021, 1, 2), 'x': 5, 'y': 7},
{'date': dt.date(2021, 1, 3), 'x': 4, 'y': 5},
{'date': dt.date(2021, 1, 4), 'x': 7, 'y': 6},
{'date': dt.date(2021, 1, 5), 'x': 3, 'y': 5},
]
s.plt.area(data=data, order=0, x='date')

Variants
By setting the parameter variant
to the following values the appearance of the chart can be changed:

Last updated
Was this helpful?