plotBy
The plotBy
method creates muliptle XY series plots per distinct grouping value specified in byColumns
.
Syntax
plotBy(seriesName, t, x, y, byColumns)
plotBy(seriesName, sds, x, y, byColumns)
Parameters
Parameter | Type | Description |
---|---|---|
seriesName | Comparable | The name you want to use to identify the series on the plot itself. |
t | Table | The table. |
sds | SelectableDataSet | Selectable data set (e.g., OneClick filterable table). |
x | String | The column in |
y | String | The column in |
byColumns | list[String] | Column(s) in |
Returns
An XY series plot with multiple series.
Examples
The following example plots data from a Deephaven table.
import static io.deephaven.csv.CsvTools.readCsv
source = readCsv("https://media.githubusercontent.com/media/deephaven/examples/main/CryptoCurrencyHistory/CSV/CryptoTrades_20210922.csv")
result = plotBy("Sept22", source, "Timestamp", "Price", "Instrument").show()