PieChartData

data class PieChartData(val slices: List<PieChartData.Slice>, val plotType: PlotType) : PlotData

PieChartData is a data class to mention all the data needed to draw slices in the pie/donut chart.

Parameters

slices

: Defines the list of slices Slice to be drawn.

plotType

: Defines the type of the chart.

Constructors

Link copied to clipboard
constructor(slices: List<PieChartData.Slice>, plotType: PlotType)

Types

Link copied to clipboard
data class Slice(val label: String, val value: Float, val color: Color, val sliceDescription: (Int) -> String = { slicePercentage -> "Slice name : $label \nPercentage : $slicePercentage %" })

Slice is data class to mention data of each arc in a 360 degree chart.

Properties

Link copied to clipboard
open override val plotType: PlotType
Link copied to clipboard
Link copied to clipboard