Krysalis jCharts
 
Built with Apache Forrest logo
  Font size:      
 

Pie Charts

PDF
PDF

2D Pie Chart Example

Here is code for a simple 2D Pie Chart...

double[] data= { 81d, 55d, 39d, 20.6d };
String[] labels= { "BMW M5", "BMW M3", "Viper GTS-R", "Corvette Z06" };
Paint[] paints= { Color.lightGray, Color.green, Color.blue, Color.red };

PieChart2DProperties pieChart2DProperties= new PieChart2DProperties();
PieChartDataSet pieChartDataSet= new PieChartDataSet( "Cars That Own",
                                                    data,
                                                    labels,
                                                    paints,
                                                    pieChart2DProperties );

PieChart2D pieChart2D= new PieChart2D( pieChartDataSet,
                                       new LegendProperties(),
                                       new ChartProperties(),
                                       400, 350 );
			
Simple 2D Pie Chart


Valid HTML 4.01!Valid CSS!