12 Answers, 1 is accepted
If you need the axis to be logarithmic - you need to use a LogarithmicAxis instead of LinearAxis. If you want the axis to appear on the right hand side, you need to use the HorizontalLocation property of the axis.
If I did not understand your requirements well, please send us snapshots of the desired result and more explanations.
Regards,
Petar Marchev
Telerik
Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.
can you give me with some demo binding datatable??
I have to bind with datatable. and this kind of Chart
You can find our Binding to a DataTable help article here. You can see how to use point series in our help documentation, sdk sample and qsf example. I hope this information helps.
Regards,
Petar Marchev
Telerik
Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.
Can you please help me to plot attached chart?? i am using below code, but can not do it, pleases find attached report image
Code here, but can not see plotting, we can see data in excel so our data seems correct.
<telerik:RadCartesianChart x:Name="chartView" Palette="Windows8">
<telerik:RadCartesianChart.VerticalAxis>
<telerik:CategoricalAxis />
</telerik:RadCartesianChart.VerticalAxis>
<telerik:RadCartesianChart.HorizontalAxis>
<telerik:LogarithmicAxis />
</telerik:RadCartesianChart.HorizontalAxis>
<telerik:RadCartesianChart.Series>
<telerik:PointSeries x:Name="barSeries1" ItemsSource="{Binding}" ShowLabels="False" />
</telerik:RadCartesianChart.Series>
</telerik:RadCartesianChart>
Everything in the xaml looks correct. Can you share the code behind too?
Regards,
Petar Marchev
Telerik
Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.
please suggest us, this is main module we need to deliver.
let us know if you need any thing else
but i have given you everything xmal. codebehind and image
void LoadChart(EscattergramViewModel _vm)
{
try
{
DataTable dt = new DataTable();
dt = _vm.DV.Table;
this.DataContext = dt.Rows;
this.barSeries1.ValueBinding =
new Telerik.Windows.Controls.ChartView.GenericDataPointBinding<DataRow, double>()
{
ValueSelector = row => (double)row["AVG"]
};
this.barSeries1.CategoryBinding =
new Telerik.Windows.Controls.ChartView.GenericDataPointBinding<DataRow, double>()
{
ValueSelector = row => (double)row["VI"]
};
}
catch (Exception ex)
{ }
}
I am unsure why you are experiencing problems on your side. I have created a simple project with the code you provided and everything works as expected. I have attached the project and a snapshot for your reference.
Regards,
Petar Marchev
Telerik
Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.
I sent you a separate email with the spreadsheet attached.
your demo code looks okay to me, but when we are plotting with real data, chart appear so badly,
you have excel data which forwarded by Mohamad, you can still use Datatable and same thing, just load this data into your example using oledb or Ado.net.
Can plot with this data?? and share code with us.
appreciate your help.
Thanks
Ashok-
how we can attached zip file here, does not allow me,
so i can attached my excel data and plot , so you can see , why not telerik generating same plot.
Thanks
I downloaded the excel file and decided to simply copy-paste the values in code behind. I successfully did that and I ran the application with no problems. However, since the values are numeric values it makes little sense to use a CategoricalAxis and the categorical PointSeries. This is why I updated the project to use a ScatterPointSeries and two numeric axes - one linear, one logarithmic.
Now the output of the chart is very similar to the image of the chart you attached. You can read more about the categorical and scatter series in our documentation (point series, scatter point series).
I will try to quickly explain the difference between the two.
The categorical series treat the categories as separate entities. Often these cannot even be compared to each other because categories may be "Bananas", "Volume", "Bolts", "4.56", "2015/01/02" and others. The categorical axis allocates a single slot for each individual category. Later the points with this category are arranged in correspondence to this axis slot.
The scatter series treat the values as values that make sense in some continuous range - such as numbers or DateTime. In the scatter series you have notion of continuity and if you have a linear range [0, 5] you can easily calculate the position of 3.14 and 2.71. However if you work with a categorical axis and you have these categories (1, 2, 3, 4, 5) - you cannot find the location of 2.5 because it is not present in the categories.
Ashok, this is s public forum thread in which you can attach only images. You can attach other files only in a private support ticket.
Let us know if you need more information.
Regards,
Petar Marchev
Telerik
Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.