Hi Steema Support,
I have a problem in plotting data in histogram plot.
Currently i have plotted it with dummy data as shown in image.
But when i look data in chart and try to understand its plotting according to X and Y scale then plotting looks different with respect to data.
Means i am unable to understand how plotting is done on the data points those are not present in X,Y data list.
Please help me to understand the logic used behind the plotting of histogram.
Regards,
PlanoResearch
Histogram plotting
-
- Guru
- Posts: 1603
- Joined: Fri Nov 15, 2002 12:00 am
Re: Histogram plotting
Hello,
The Histogram series is optimized to draw series with equi-distant X values. Where data has disparate X values it is better to use an Area series with Stairs, e.g.
The Histogram series is optimized to draw series with equi-distant X values. Where data has disparate X values it is better to use an Area series with Stairs, e.g.
Code: Select all
private void InitializeChart()
{
double[] xvalues = new double[] { 827, 837, 897, 929, 968, 1009, 1014, 1017, 1026, 1027, 1044, 1066, 1088, 1110, 1113, 1115, 1148, 1196, 1207, 1213, 1297, 1300, 1334, 1343, 1365 };
double[] yvalues = new double[] { 2, 1, 0, 3, 14, 5, 4, 17, 18, 20, 13, 15, 16, 21, 19, 6, 12, 11, 7, 22, 8, 10, 23, 34, 9 };
if(xvalues.Length == yvalues.Length)
{
Area series = new Area(tChart1.Chart);
series.Stairs = true;
series.Add(xvalues, yvalues);
}
}
Best Regards,
Christopher Ireland / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |
Re: Histogram plotting
Hi Christopher,
You are right, but my need is that i have to filter data(means remove unwanted data) using histogram.
I am also little bit confused how i achieve this.
If you have any suggestion on this we will appreciate.
Regards,
PlanoResearch
You are right, but my need is that i have to filter data(means remove unwanted data) using histogram.
I am also little bit confused how i achieve this.
If you have any suggestion on this we will appreciate.
Regards,
PlanoResearch
-
- Guru
- Posts: 1603
- Joined: Fri Nov 15, 2002 12:00 am
Re: Histogram plotting
Why can't you filter data using the Area series?amol wrote: You are right, but my need is that i have to filter data(means remove unwanted data) using histogram.
I am also little bit confused how i achieve this.
Best Regards,
Christopher Ireland / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |
Re: Histogram plotting
Hi Christopher,
Actually my need is to plot data using Histogram.
I have also gone through with excel charts here i have plotted my data. i m attaching images of same. On excel my data plotted correctly. i want to plot similar in teechart.
As shown in first image data is plotted on histogram chart with 3 bins.
As shown in second image i have changed number of bins to 5. And after changing number of pillar/bars increased.
But in third image i have plotted same data with teechart but it plots data differently. why?
One more thing in teechart histogram, there is no property to set bins number. And my need is to change bins dynamically over the plotted data.
Kindly help i want to plot similar chart using teechart as plotted in excel.
Regards,
PlanoResearch
Actually my need is to plot data using Histogram.
I have also gone through with excel charts here i have plotted my data. i m attaching images of same. On excel my data plotted correctly. i want to plot similar in teechart.
As shown in first image data is plotted on histogram chart with 3 bins.
As shown in second image i have changed number of bins to 5. And after changing number of pillar/bars increased.
But in third image i have plotted same data with teechart but it plots data differently. why?
One more thing in teechart histogram, there is no property to set bins number. And my need is to change bins dynamically over the plotted data.
Kindly help i want to plot similar chart using teechart as plotted in excel.
Regards,
PlanoResearch
-
- Guru
- Posts: 1603
- Joined: Fri Nov 15, 2002 12:00 am
Re: Histogram plotting
Please bear in mind that, as a business, we cannot dedicate very much time to helping you write your applications without receiving payment for it. So any help you can give us whereby we can spend less time helping your write your applications is greatly appreciated. TeeChart was not specifically designed to replicate Excel functionality nor has it ever been sold as doing so, and as such we do not feel obliged to spend time, without payment, producing code which replicates Excel.amol wrote: But in third image i have plotted same data with teechart but it plots data differently. why?
One more thing in teechart histogram, there is no property to set bins number. And my need is to change bins dynamically over the plotted data.
Kindly help i want to plot similar chart using teechart as plotted in excel.
In this particular case, then, could you please spend some time making an attempt to produce the functionality you need so that we can run this code here to save us the time of writing it ourselves. As a guide you may like to consider Stackoverflow's directives for a Minimal, Complete, and Verifiable (MCVE) example you can read about here. Once in receipt of the MCVE you have written for us we can then help you in achieving your final goals.
Thank you.
Best Regards,
Christopher Ireland / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |
Re: Histogram plotting
Hi Steema Support,
As you suggested i am attaching demo for your help. Please find it from attachment.
We are using teechart version 2012.
regards,
Planoresearch
As you suggested i am attaching demo for your help. Please find it from attachment.
We are using teechart version 2012.
regards,
Planoresearch
-
- Guru
- Posts: 1603
- Joined: Fri Nov 15, 2002 12:00 am
Re: Histogram plotting
That you are using version 2012 means that it is six years since you have paid Steema for an upgrade. If all our clients did not pay for upgrades Steema would soon be out of business!amol wrote: As you suggested i am attaching demo for your help. Please find it from attachment.
We are using teechart version 2012.
I have run your test project, but as far as I can see it does not reproduce a problem with TChart here. Neither does the project give any indication of your requirements, nor has any effort been made to produce a project which clearly shows where your problem is.
Best Regards,
Christopher Ireland / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |