Page 1 of 1

Spider Chart

Posted: Fri Oct 01, 2004 10:36 am
by 4209803
hi,
i'm new and i need help creating a spider chart displayed in the following image.

Image

it's necessary to create mor than 2 axes (4 sections). how do i create such a chart?

Posted: Fri Oct 01, 2004 1:14 pm
by Marjan
Hi.

For actual chart you can use polar series with one of pre-defined brush styles. Adding custom axes is a bit more tricky, but I guess it could be done by manually drawing required arrows directly on chart Canvas by using one of it's drawing methods (Arrow or even combination of lineto+moveto). Please note that all drawing code should be placed in one of the Chart events. There are several examples about drawing custom objects available in Teechart demo. Also, several topics in this forum address similar problems when user has to manuallly draw objects on chart Canvas.

Posted: Fri Oct 01, 2004 1:49 pm
by 4209803
the arrows on the axes are not really important.
the important thing is that i get more axes than those shown in the image following.

Image

i used a TPolarSeries, which works fine. but how do i get additional axes like in the image in my first post. (two 45° axes)
this is the point which have to be solved!

Posted: Mon Oct 04, 2004 7:00 am
by Pep
Hi,
i used a TPolarSeries, which works fine. but how do i get additional axes like in the image in my first post. (two 45° axes)
As Marjan said :
axes is a bit more tricky, but I guess it could be done by manually drawing required arrows directly on chart Canvas by using one of it's drawing methods (Arrow or even combination of lineto+moveto).

There's no way to add these axis type directly.

Posted: Tue Oct 12, 2004 3:10 pm
by 4209803
so what do i have to do to create such pseudo-axes?

who do i get the center of the chart?

Posted: Thu Oct 14, 2004 4:38 pm
by Pep
Hi,

you could use similar code to the following :

Code: Select all

procedure TForm1.Chart1AfterDraw(Sender: TObject);
begin
with Chart1 do
begin
  Canvas.Pen.Width := 2;
  Canvas.MoveTo(Chart1.Axes.Bottom.IStartPos,Chart1.Axes.Bottom.PosAxis);
  Canvas.LineTo(Chart1.Axes.bottom.IEndPos-50,55);
end;
end;

Posted: Thu Oct 28, 2004 6:45 am
by 4209803
Pep wrote:Hi,

you could use similar code to the following :

Code: Select all

procedure TForm1.Chart1AfterDraw(Sender: TObject);
begin
with Chart1 do
begin
  Canvas.Pen.Width := 2;
  Canvas.MoveTo(Chart1.Axes.Bottom.IStartPos,Chart1.Axes.Bottom.PosAxis);
  Canvas.LineTo(Chart1.Axes.bottom.IEndPos-50,55);
end;
end;
sorry, but this code doesn't work! :(

the compiler does not know "Chart1.Axes.Bottom"!

i'm using D6 Enterprise with TeeChart 5.02

Posted: Thu Oct 28, 2004 2:41 pm
by Pep
Hi,
the compiler does not know "Chart1.Axes.Bottom"!

i'm using D6 Enterprise with TeeChart 5.02
In that case you must use the old one (which still existing in the latest versions) :
Chart1.BottomAxis