Package org.krysalis.jcharts.chartData

Examples of org.krysalis.jcharts.chartData.DataSeries


  {
    String[] xAxisLabels= { "1998", "1999", "2000", "2001", "2002", "2003", "2004" };
    String xAxisTitle= "Years";
    String yAxisTitle= "Problems";
    String title= "Micro$oft at Work";
    DataSeries dataSeries = new DataSeries( xAxisLabels, xAxisTitle, yAxisTitle, title );


    double[][] data= TestDataGenerator.getRandomNumbers( 3, 7, 0, 5000 );
    String[] legendLabels= { "Bugs", "Security Holes", "Backdoors" };
    Paint[] paints= TestDataGenerator.getRandomPaints( 3 );

    AreaChartProperties areaChartProperties= new AreaChartProperties();
    AxisChartDataSet axisChartDataSet= new AxisChartDataSet( data, legendLabels, paints, ChartType.AREA, areaChartProperties );
    dataSeries.addIAxisPlotDataSet( axisChartDataSet );


    data= TestDataGenerator.getRandomNumbers( 2, 7, 1000, 5000 );
    legendLabels= new String[]{ "Patches", "New Patch Bugs" };
    paints= new Paint[]{ Color.black, Color.red };

    Stroke[] strokes= { LineChartProperties.DEFAULT_LINE_STROKE, LineChartProperties.DEFAULT_LINE_STROKE };
    Shape[] shapes= { PointChartProperties.SHAPE_CIRCLE, PointChartProperties.SHAPE_TRIANGLE };
    LineChartProperties lineChartProperties= new LineChartProperties( strokes, shapes );
    axisChartDataSet= new AxisChartDataSet( data, legendLabels, paints, ChartType.LINE, lineChartProperties );
    dataSeries.addIAxisPlotDataSet( axisChartDataSet );


    ChartProperties chartProperties= new ChartProperties();
    AxisProperties axisProperties= new AxisProperties();
    LegendProperties legendProperties= new LegendProperties();
View Full Code Here



    AxisChartDataSet axisChartDataSet;


    DataSeries dataSeries = super.createDataSeries( dataSize );

    axisChartDataSet = super.createAxisChartDataSet( ChartType.BAR,
                                     getChartTypeProperties( numberOfDataSets ),
                                     numberOfDataSets,
                                     dataSize,
                                     -200,
                                     400 );

    dataSeries.addIAxisPlotDataSet( axisChartDataSet );

    return dataSeries;
  }
View Full Code Here

    String[] legendLabels = {"Test Legend Label"};
    AxisChartDataSet axisChartDataSet = new AxisChartDataSet( data, legendLabels, paints, ChartType.BAR, barChartProperties );

    String[] axisLabels = {"1900", "2000", "2010", "2050" };
    //String[] axisLabels = {"1900", "1910", "1920", "1930", "1940", "1950", "1960", "1970", "1980", "1990", "2000" };
    IAxisDataSeries dataSeries = new DataSeries( axisLabels, "Wonka Bars", "Years", "Oompa Loompa Productivity" );
    dataSeries.addIAxisPlotDataSet( axisChartDataSet );


    ChartProperties chartProperties = new ChartProperties();
    AxisProperties axisProperties = new AxisProperties( false );
View Full Code Here

  {
    String[] xAxisLabels = {"1998", "1999", "2000", "2001", "2002", "2003", "2004"};
    String xAxisTitle = "Years";
    String yAxisTitle = "Problems";
    String title = "Micro$oft at Work";
    DataSeries dataSeries = new DataSeries( xAxisLabels, xAxisTitle, yAxisTitle, title );

    dataSeries.addIAxisPlotDataSet( AxisChartsGuide.createAxisChartDataSet( ChartType.AREA, new AreaChartProperties(), 200, 5000 ) );

    ChartProperties chartProperties = new ChartProperties();
    LegendProperties legendProperties = new LegendProperties();

    AxisChart axisChart = new AxisChart( dataSeries, chartProperties, axisProperties, legendProperties, AxisChartsGuide.width, AxisChartsGuide.height );
View Full Code Here

    Paint[] paints = {Color.blue};
    String xAxisTitle = "Months";
    String yAxisTitle = "Bugs";
    String title = "Micro$oft At Work";

    DataSeries dataSeries = new DataSeries( xAxisLabels, xAxisTitle, yAxisTitle, title );
    AxisChartDataSet axisChartDataSet = new AxisChartDataSet( data, legendLabels, paints, ChartType.BAR, new BarChartProperties() );

    dataSeries.addIAxisPlotDataSet( axisChartDataSet );

    AxisChart axisChart = new AxisChart( dataSeries, new ChartProperties(), axisProperties, new LegendProperties(), width, height );
    super.exportImage( axisChart, "horizontalPlots" );
  }
View Full Code Here

    Paint[] paints = {Color.blue};
    String xAxisTitle = "Months";
    String yAxisTitle = "Bugs";
    String title = "Micro$oft At Work";

    DataSeries dataSeries = new DataSeries( xAxisLabels, xAxisTitle, yAxisTitle, title );
    AxisChartDataSet axisChartDataSet = new AxisChartDataSet( data, legendLabels, paints, ChartType.AREA, new AreaChartProperties() );

    dataSeries.addIAxisPlotDataSet( axisChartDataSet );

    AxisChart axisChart = new AxisChart( dataSeries, new ChartProperties(), axisProperties, new LegendProperties(), width, height );
    super.exportImage( axisChart, "gridLines" );
  }
View Full Code Here

    String yAxisTitle = "Bugs";
    String title = "Micro$oft At Work";
    AxisChartDataSet axisChartDataSet = new AxisChartDataSet( data, legendLabels, paints, ChartType.AREA, new AreaChartProperties() );


    DataSeries dataSeries = new DataSeries( xAxisLabels, null, yAxisTitle, title );
    dataSeries.addIAxisPlotDataSet( axisChartDataSet );

    AxisChart axisChart = new AxisChart( dataSeries, new ChartProperties(), new AxisProperties(), new LegendProperties(), width, height );
    super.exportImage( axisChart, "axisTitles" );

    AxisProperties axisProperties = new AxisProperties();
View Full Code Here

    String[] xAxisLabels = { "1998", "1999", "2000", "2001", "2002", "2003", "2004" };
    String xAxisTitle = "Years";
    String yAxisTitle = "Problems";
    String title = null;

    return new DataSeries( xAxisLabels, xAxisTitle, yAxisTitle, "Micro$oft At Work" );
  }
View Full Code Here

   *
   *
   ******************************************************************************************/
  DataSeries getDataSeries() throws ChartDataException
  {
    DataSeries dataSeries= null;

    int dataSize = (int) TestDataGenerator.getRandomNumber( 3, 3 );
    int numberOfDataSets = (int) TestDataGenerator.getRandomNumber( 1, 1 );

    //ScatterPlotDataSet scatterPlotDataSet= this.createScatterPlotDataSet(  )
View Full Code Here

            Paint[] paint = new Paint[labels.length];
            for(int j = 0 ; j < paint.length ; j++) {
              paint[j] = availablecolors[j];
            }
            AxisChartDataSet axisChartDataSet = new AxisChartDataSet(points,labels,paint,ChartType.LINE,lineChartProperties);
            DataSeries dataSeries = new DataSeries(xAxisLabels,"Date","Time in Hours","Online Statistics for " + jid);
            dataSeries.addIAxisPlotDataSet(axisChartDataSet);
           
            ChartProperties chartProperties = new ChartProperties();
            AxisProperties axisProperties = new AxisProperties( );
            axisProperties.setXAxisLabelsAreVertical(true);
            DataAxisProperties dataAxisProperties= (DataAxisProperties) axisProperties.getYAxisProperties();
View Full Code Here

TOP

Related Classes of org.krysalis.jcharts.chartData.DataSeries

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.