Bubble Chart on RadChartView

2 posts, 0 answers
  1. Mark Oldytowski
    Mark Oldytowski avatar
    3 posts
    Member since:
    Jul 2009

    Posted 22 Aug 2012 Link to this post

    Can you provide an example of a data bound Bubble Chart using the new RadChartView controls? I have seen a few examples using the old RadChart controls but none as of yet using RadChartView.

    Thanks,

    Mark
  2. Petar Marchev
    Admin
    Petar Marchev avatar
    968 posts

    Posted 27 Aug 2012 Link to this post

    Hi Mark,

    The RadChartView does not offer Bubble Series. This feature is still not in our development plans and currently this is not supported.

    However I think that in some scenarios it would be a feasible solution to use ScatterPointSeries and define a PointTemplate, in which you can place an Ellipse which size is defined by a property of the underlying business item:
    <telerik:ScatterPointSeries.PointTemplate>
     <DataTemplate>
      <Ellipse Width="{Binding DataItem.BubbleSize}" Height="{Binding DataItem.BubbleSize}" Fill="Blue"/>

    One little trick you must apply is set the Width and Height of the ContentPresenter which hosts the Ellipse to be enough to accomodate the largest bubble possible. I have attached a simple app to demonstrate this, and a snapshot of the output that I get when I run the app. In the attached project, the largest possible bubble is 80x80 and this is why I have set this code:
    <telerik:ScatterPointSeries.Resources>
     <Style TargetType="ContentPresenter">
      <Setter Property="Height" Value="80" />
      <Setter Property="Width" Value="80" />

    Give this approach a try and see if you can adopt it to your current project.

    Regards,
    Petar Marchev
    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

  3. UI for WPF is Visual Studio 2017 Ready
Back to Top