krysalis-jcharts/src/documentation/content/xdocs/userGuide/axisCharts/line properties.xml,NONE,1.1 index.xml,1.2,1.3 book.xml,1.1,1.2
"Nathaniel G. Auvil" <[email protected]> Tue, 27 Jul 2004 00:50:52 +0000
| Newsgroups | gmane.comp.krysalis.jcharts.cvs |
|---|---|
| Message-ID | <[email protected]> |
Update of /cvsroot/jcharts/krysalis-jcharts/src/documentation/content/xdocs/userGuide/axisCharts/line
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv19093/src/documentation/content/xdocs/userGuide/axisCharts/line
Modified Files:
index.xml book.xml
Added Files:
properties.xml
Log Message:
--- NEW FILE: properties.xml ---
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V1.1//EN" "document-v11.dtd">
<document>
<header>
<title>Line Charts</title>
</header>
<body>
<section>
<title>Line Stroke</title>
<p>
You can specify any <code>java.awt.Stroke</code> Implementation desired to the <code>LineChartProperties</code> Constructor.
</p>
<source>
Stroke[] strokes= new Stroke[ 2 ];
strokes[ 0 ]= new BasicStroke( 3.5f, BasicStroke.CAP_ROUND, BasicStroke.JOIN_ROUND, 5f, new float[]{ 5f, 5f, 10f, 5f}, 4f );
strokes[ 1 ]= new BasicStroke( 5.0f );
Shape[] shapes= { PointChartProperties.SHAPE_CIRCLE, null };
LineChartProperties lineChartProperties= new LineChartProperties( strokes, shapes );
</source>
<figure src="images/userGuide/lineCharts/strokes.png" alt="Line Chart Strokes"/>
</section>
<section>
<title>Missing Values</title>
<p>
You can show missing values on Line Charts by using <code>Double.NaN</code> values in your dataset.
</p>
<source>
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= new double[][]{ { 250, 45, -36, 66, 145, 80, 55 } };
data[ 0 ][ 3 ]= Double.NaN;
data[ 0 ][ 4 ]= Double.NaN;
String[] legendLabels= { "Bugs" };
Paint[] paints= TestDataGenerator.getRandomPaints( 1 );
Stroke[] strokes= { LineChartProperties.DEFAULT_LINE_STROKE };
Shape[] shapes= { PointChartProperties.SHAPE_CIRCLE };
LineChartProperties lineChartProperties=
new LineChartProperties( strokes, shapes );
AxisChartDataSet axisChartDataSet= new AxisChartDataSet( data,
legendLabels,
paints,
ChartType.LINE,
lineChartProperties );
dataSeries.addIAxisPlotDataSet( axisChartDataSet );
ChartProperties chartProperties= new ChartProperties();
AxisProperties axisProperties= new AxisProperties();
LegendProperties legendProperties= new LegendProperties();
AxisChart axisChart= new AxisChart( dataSeries,
chartProperties,
axisProperties,
legendProperties,
AxisChartsGuide.width,
AxisChartsGuide.height );
</source>
<figure src="images/userGuide/lineCharts/missingValues.png" alt="Missing Values"/>
</section>
</body>
</document>
Index: index.xml
===================================================================
RCS file: /cvsroot/jcharts/krysalis-jcharts/src/documentation/content/xdocs/userGuide/axisCharts/line/index.xml,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** index.xml 5 Jun 2004 16:17:38 -0000 1.2
--- index.xml 27 Jul 2004 00:50:50 -0000 1.3
***************
*** 7,14 ****
<body>
<section>
! <title>Line Charts</title>
<p>
</p>
</section>
</body>
--- 7,52 ----
<body>
<section>
! <title>Line Chart</title>
<p>
</p>
+ <source>
+ 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= new double[][]{ { 250, 45, -36, 66, 145, 80, 55 } };
+ String[] legendLabels= { "Bugs" };
+ Paint[] paints= TestDataGenerator.getRandomPaints( 1 );
+
+ Stroke[] strokes= { LineChartProperties.DEFAULT_LINE_STROKE };
+ Shape[] shapes= { PointChartProperties.SHAPE_CIRCLE };
+ LineChartProperties lineChartProperties=
+ new LineChartProperties( strokes, shapes );
+
+ AxisChartDataSet axisChartDataSet= new AxisChartDataSet( data,
+ legendLabels,
+ paints,
+ ChartType.LINE,
+ lineChartProperties );
+ dataSeries.addIAxisPlotDataSet( axisChartDataSet );
+
+ ChartProperties chartProperties= new ChartProperties();
+ AxisProperties axisProperties= new AxisProperties();
+ LegendProperties legendProperties= new LegendProperties();
+
+ AxisChart axisChart= new AxisChart( dataSeries,
+ chartProperties,
+ axisProperties,
+ legendProperties,
+ AxisChartsGuide.width,
+ AxisChartsGuide.height );
+ </source>
+ <figure src="images/userGuide/lineCharts/basicChart.png" alt="Line Chart"/>
</section>
</body>
Index: book.xml
===================================================================
RCS file: /cvsroot/jcharts/krysalis-jcharts/src/documentation/content/xdocs/userGuide/axisCharts/line/book.xml,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** book.xml 5 Jun 2004 14:25:57 -0000 1.1
--- book.xml 27 Jul 2004 00:50:50 -0000 1.2
***************
*** 5,15 ****
<book software="jCharts"
! title="Axis Charts - Common"
copyright="@year@ The Krysalis Software Foundation"
xmlns:xlink="http://www.w3.org/1999/xlink">
! <menu label="Area Charts">
! <menu-item label="Simple" href="index.html"/>
<menu-item label="Back" href="../index.html"/>
</menu>
--- 5,16 ----
<book software="jCharts"
! title="Axis Charts - Line Chart"
copyright="@year@ The Krysalis Software Foundation"
xmlns:xlink="http://www.w3.org/1999/xlink">
! <menu label="Line Charts">
! <menu-item label="Line" href="index.html"/>
! <menu-item label="Properties" href="properties.html"/>
<menu-item label="Back" href="../index.html"/>
</menu>
-------------------------------------------------------
This SF.Net email is sponsored by BEA Weblogic Workshop
FREE Java Enterprise J2EE developer tools!
Get your free copy of BEA WebLogic Workshop 8.1 today.
http://ads.osdn.com/?ad_id=4721&alloc_id=10040&op=click