How to add a Histogram

TeeChart VCL for Borland/CodeGear/Embarcadero RAD Studio, Delphi and C++ Builder.
Post Reply
Sciensoria
Newbie
Newbie
Posts: 20
Joined: Tue Jul 03, 2007 12:00 am
Contact:

How to add a Histogram

Post by Sciensoria » Wed Oct 01, 2014 12:38 pm

Hello,
This is a new subject. However, I don't know how to make a new post because I didn't find any button other than "postreply".
I want to add a histogram to an existing curve on a chart. The aim is to give a statistic of the data contained in the curve. So, I intend to use a THorizLineSeries to represent the histogram which will show confident range among the values of the curves.
The problem is I didn't find any example to do it.
Could you show me how to add the histogram, connect it to the existing series, set the function to "histogram", set the number of bins (as referred to the Matlab function hist(x,n) where x is the data and n is the number of bins (classes of data)) ?
Please give the example in Delphi.
Thank you in advance

LÊ Minh-Quang
Sciensoria

PS : thank you very much for your support you have given from 2007

Yeray
Site Admin
Site Admin
Posts: 9612
Joined: Tue Dec 05, 2006 12:00 am
Location: Girona, Catalonia
Contact:

Re: How to add a Histogram

Post by Yeray » Thu Oct 02, 2014 7:55 am

Sciensoria wrote:This is a new subject. However, I don't know how to make a new post because I didn't find any button other than "postreply".
I've split this message you posted in this thread to a new thread here.
To open a new thread, you should go to a forum category (ie VCL / CLX) and click on the "NEWTOPIC" button:
new_topic.png
new_topic.png (63.14 KiB) Viewed 7340 times
Best Regards,
ImageYeray Alonso
Development & Support
Steema Software
Av. Montilivi 33, 17003 Girona, Catalonia (SP)
Image Image Image Image Image Image Please read our Bug Fixing Policy

Yeray
Site Admin
Site Admin
Posts: 9612
Joined: Tue Dec 05, 2006 12:00 am
Location: Girona, Catalonia
Contact:

Re: How to add a Histogram

Post by Yeray » Thu Oct 02, 2014 8:09 am

Hello,
Sciensoria wrote:I want to add a histogram to an existing curve on a chart. The aim is to give a statistic of the data contained in the curve. So, I intend to use a THorizLineSeries to represent the histogram which will show confident range among the values of the curves.
The problem is I didn't find any example to do it.
Could you show me how to add the histogram, connect it to the existing series, set the function to "histogram", set the number of bins (as referred to the Matlab function hist(x,n) where x is the data and n is the number of bins (classes of data)) ?
Please give the example in Delphi.
I'd suggest you to read the "Tutorial 7 - Working with Functions", shipped with the binary installation, to understand how the functions work in TeeChart.

Then, you'll find example about the Histogram function at "All features\Welcome !\Functions\Statistical\Histogram" in the Features Demo program also shipped with the binary installation. Look at the "Source Code" and "Form" tabs at the bottom to find all the code (Delphi).
Histogram.png
Histogram.png (165.11 KiB) Viewed 7337 times
Sciensoria wrote:PS : thank you very much for your support you have given from 2007
You are welcome! :)
Best Regards,
ImageYeray Alonso
Development & Support
Steema Software
Av. Montilivi 33, 17003 Girona, Catalonia (SP)
Image Image Image Image Image Image Please read our Bug Fixing Policy

Post Reply