Data point with exact same x and y values

Hi

What happens in a series when there are Data points with exact same X and Y values?

  1. Will there be multiple points stored in memory?
  2. Will there be multiple points plotted on the chart?

Thanks and hope to hear from you soon.



3 Replies

YG Yuvaraj Gajaraj Syncfusion Team October 19, 2021 03:26 PM UTC

Hi Peter, 
 
Greetings from Syncfusion. We have analyzed your query and we would like to inform you that, the multiple points will be stored, and all the provided data will be plotted on the chart. 
We have also attached the sample with exact same x and y value for you reference. 
 
  
If this is not your scenario, kindly get back to us with more information on your query regarding same x and y values and how you need to behave. 
  
Regards, 
Yuvaraj.


PE Peter October 20, 2021 02:20 AM UTC

Hi

Thanks for replying.

Is there a way to remove duplicate data points that have exact x/y values?



YG Yuvaraj Gajaraj Syncfusion Team October 20, 2021 01:50 PM UTC

Hi Peter, 
  
We have analyzed your query, and we created a workaround for your scenario in which we have removed if both x and y values are same. We have attached sample for your reference which can be found below, and this can be changed based on your scenario.  
  
Code: 
  
  //In this method we have removed when both x and y values are same,  
  //you can change this based on your scenario 
  List<ChartData> removeDuplicateData(List<ChartData> data) { 
    //... 
  } 
 
  
  
Regards, 
Yuvaraj 


Loader.
Up arrow icon