Created
November 5, 2020 07:01
-
-
Save Shestac92/472b9512eabc07ff9864c1a90b02f0a7 to your computer and use it in GitHub Desktop.
2x-Ordinal Cartesian chart
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
AnyChartView anyChartView = findViewById(R.id.any_chart_view); | |
List<DataEntry> data = new ArrayList<>(); | |
data.add(new CustomDataEntry("2020/05/23", "TripTone360")); | |
data.add(new CustomDataEntry("2025/05/23", "Trip")); | |
Cartesian chart = AnyChart.cartesian(); | |
chart.xAxis(0).enabled(true); | |
chart.yAxis(0).enabled(true); | |
JumpLine series = chart.jumpLine(data); | |
Ordinal yScale = Ordinal.instantiate(); | |
chart.yScale(yScale); | |
anyChartView.setChart(chart); | |
private class CustomDataEntry extends DataEntry { | |
CustomDataEntry(String x, String value) { | |
setValue("x", x); | |
setValue("value", value); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment