TeeChart VCL for Borland/CodeGear/Embarcadero RAD Studio, Delphi and C++ Builder.
-
ghorwin
- Newbie
- Posts: 15
- Joined: Thu Oct 04, 2007 12:00 am
Post
by ghorwin » Tue Oct 09, 2007 10:16 pm
Hi there,
I create a TSurfaceSeries and fill the data in with the following code:
Code: Select all
// loop over all time points
for (unsigned int i=0; i < z_matrix.size(); ++i) {
// loop over all coordinates
for (unsigned int j = 0; j<y_vec.size(); ++j) {
series3D->AddXYZ(x_vec[i], z_matrix[i].m_data[j], y_vec[j]);
}
}
The result is the following chart:
If I replace the y_vec[j] simply with j I get a full surface. The vector y_vec[j] is large enough and contains data from 0.5 to 119.5.
What could be the reason for this strange behavior?
Andreas
-
Narcís
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
-
Contact:
Post
by Narcís » Wed Oct 10, 2007 9:44 am
Hi Andreas,
It may be that you need to set IrregularGrid property to true as described on
this thread.
Hope this helps!
-
ghorwin
- Newbie
- Posts: 15
- Joined: Thu Oct 04, 2007 12:00 am
Post
by ghorwin » Wed Oct 10, 2007 2:50 pm
Yup, that worked! Thanks a ton!
Andreas