Hello,
1. Can anyone tell me how could I get to make Points on my chart for every data point with Numerical as Y-Value and Categorical as X-Value?
I tried to make it with ScatterPointSeries. It worked on iOS, but crash on android. Because originally ScatterPointSeries uses numerical for both X & Y Values (Code below)
2. And , kindly check my RadLegend on my code as well, it does not show.
Thank you.
var hAxis = new CategoricalAxis();
hAxis.LabelFontSize = 6;
var vAxis = new NumericalAxis();
vAxis.LabelFontSize = 7;
vAxis.LabelFormat = "#,#.#";
chart = new RadCartesianChart
{
HorizontalAxis = hAxis,
VerticalAxis = vAxis,
VerticalOptions = LayoutOptions.FillAndExpand,
HorizontalOptions = LayoutOptions.FillAndExpand
};
ScatterPointSeries point = new ScatterPointSeries();
point.SetBinding(ChartSeries.ItemsSourceProperty, new Binding(itemSource));
point.YValueBinding = new PropertyNameDataPointBinding(valueBinding);
point.XValueBinding = new PropertyNameDataPointBinding(categoryBinding);
point.ShowLabels = true;
point.LabelBinding = new PropertyNameDataPointBinding(labelBinding);
chart.Series.Add(point);
var legend = new RadLegend
{
LegendProvider = chart,
HeightRequest = 100,
LegendItemFontColor = Color.DarkGreen,
Orientation = LegendOrientation.Horizontal,
};
stacklayoutView.Children.Add(chart); //usual stacklayout on absolute layout