Color of outliers in Boxplot

TeeChart VCL for Borland/CodeGear/Embarcadero RAD Studio, Delphi and C++ Builder.
Post Reply
emwamin
Newbie
Newbie
Posts: 6
Joined: Fri Nov 11, 2011 12:00 am

Color of outliers in Boxplot

Post by emwamin » Wed Feb 15, 2012 11:15 am

Hi.
In the my Boxplot the outliers (shown as points) are colored by the chart itself and not by me. Does the coloring have a meaning?
Can I set the outliers color to colors of my choice? if yes, How?

outliers.jpg
outliers.jpg (14.29 KiB) Viewed 5930 times

BR
emwamin

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

Re: Color of outliers in Boxplot

Post by Yeray » Fri Feb 17, 2012 4:19 pm

Hi emwamin,

The color of the outliers is taken from the series' color. By default, when a series is created, it takes the next color in the Opera Palette. That's why the outliers have these colors set, but you can change them as you want:

Code: Select all

uses TeeBoxPlot;

procedure TForm1.FormCreate(Sender: TObject);
var i: Integer;
begin
  Chart1.View3D:=false;

  for i:=0 to 3 do
    with Chart1.AddSeries(TBoxSeries) as TBoxSeries do
    begin
      FillSampleValues();
      Position:=i;
      Box.Color:=clGreen;
      Color:=clRed;
    end;
end;
Boxes.png
Boxes.png (9.59 KiB) Viewed 5813 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

Post Reply