plotStyle
plotStyle
alters the style of a XY series and category charts.
Syntax
plotStyle(plotStyle)
Parameters
Parameter | Type | Description |
---|---|---|
plotStyle | String | The plot style to apply. The following options are available:
These arguments are case insensitive. |
Examples
The following example creates a single series plot using the stacked_area
style.
import static io.deephaven.csv.CsvTools.readCsv
//source the data
source = readCsv("https://media.githubusercontent.com/media/deephaven/examples/main/MetricCentury/csv/metriccentury.csv")
//apply a plot style
plot_single_stacked_area= plot("Heart_rate", source, "Time", "HeartRate").plotStyle("stacked_area")\
.show()
- source
- plot_single_stacked_area
The following example creates a category plot with the stacked_bar
style.
sourceOne = newTable(
stringCol("Categories", "A", "B", "C"),
intCol("Values", 1, 3, 5)
)
sourceTwo = newTable(
stringCol("Categories", "A", "B", "C"),
intCol("Values", 2, 4, 6)
)
result = catPlot("Categories Plot One", sourceOne, "Categories", "Values")
.catPlot("Categories Plot Two", sourceTwo, "Categories", "Values")
.plotStyle("stacked_bar")
.chartTitle("Categories And Values")
.show()
- sourceOne
- sourceTwo
- result