Incorrect Value in Telerik Chart Sample

2 posts, 0 answers
  1. elie
    elie avatar
    3 posts
    Member since:
    Aug 2010

    Posted 31 Aug 2010 Link to this post

    Hi everyone,
    I copy the basics Bar Sample  Chart from Telerik website.
    I change the sourceitems to an array of double of length 250.
    Every value equal to  100, just one of them equal to 1000.

    In the Chart I see incorrect value, instead of display a bar with 1000, I see a bar with 550.
    Can anyone help me??
    Thank you.

    Here are the code:
     

     

     

    public Example()

     {

        InitializeComponent();

        RadChart1.DefaultView.ChartArea.EnableAnimations =

     

        false;

     

     

     }

     

     

     

     

    void Example_Loaded(object sender, RoutedEventArgs e)

     {

     

     

        this.FillSampleChartData();

     

     

     }

     

     

     

     

    private void FillSampleChartData()

     {

     

     

        double[] data = new double[250];

     

     

     

     

        for (int i = 0; i < data.Length; i++)

     

             data[i] = 100;

        
        data[178] = 1000;

     

        RadChart1.DefaultSeriesDefinition =

         

    new BarSeriesDefinition();

     

     

         RadChart1.ItemsSource = data;

    }

     

     

  2. Yavor
    Admin
    Yavor avatar
    11 posts

    Posted 02 Sep 2010 Link to this post

    Hi elie,

    I believe that the described behavior is due to the sampling of the control. Additional information is available in the following article:

    http://www.telerik.com/help/silverlight/radchart-features-sampling.html

    you can disable it by setting the SamplingThreshold to a value of 0.
    I hope this information helps.

    All the best,
    Yavor
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Back to Top