SciChart® the market leader in Fast WPF Charts, WPF 3D Charts, iOS Chart, Android Chart and JavaScript Chart Components
Referring to the stacked column side by side example in the android examples collection, if someone clicks on a column/series in that chart, how could i identify which the of columns has been selected (usa, china, india, etc).
Hi Marcus,
I’m afraid we have a limited support of SeriesSelectionModifier for stacked series, because it can only select/deselect entire renderable series from renderable series collection of chart, so in case of stacked series it can only select/deselect all series or none of them. To add proper support for stacked series you would need to create custom selection modifier.
Theretically you can use our hit test API ( we have an example which shows how to use it ) to determine which renderable series was hit at specified coordinates of chart (https://www.scichart.com/documentation/android/current/webframe.html#SciChart.Charting~com.scichart.charting.visuals.renderableSeries.hitTest.HitTestInfo~hitRenderableSeries.html). You can get series name from this HitTestInfo like this and check if match name set for DataSeries(e.g. USA, China, India etc ):
final IRenderableSeries hitRenderableSeries = hitTestInfo.hitRenderableSeries;
if(hitRenderableSeries != null) {
final String seriesName = hitRenderableSeries.getDataSeries().getSeriesName();
}
Hope this will help you!
Best regards,
Yura
Please login first to submit.