Difference between revisions of "Documentation/DevGuide/Charts/Statistics"

From Apache OpenOffice Wiki
Jump to: navigation, search
m (1 revision(s))
m (Robot: Changing Category:Charts)
Line 30: Line 30:
  
 
{{PDL1}}
 
{{PDL1}}
[[Category: Charts]]
+
 
 +
[[Category:Documentation/Developers Guide/Charts]]

Revision as of 09:01, 4 June 2008



Statistical properties like error indicators or regression curves can be applied. The regression curves can only be used for xy-diagrams that have tuples of values for each data point. The following example shows how to add a linear regression curve to an xy-diagram.

Additionally, the mean value line is displayed and error indicators for the standard deviation are applied.

 // get the diagram
 // ...
 
 // get the properties of a single series
 XPropertySet aProp = maDiagram.getDataRowProperties(1)
 
 // set a linear regression
 aProp.setPropertyValue("RegressionCurves", ChartRegressionCurveType.LINEAR);
 
 // show a line at y = mean of the series' values
 aProp.setPropertyValue("MeanValue", new Boolean(true));
 
 // add error indicators in both directions
 // with the length of the standard deviation
 aProp.setPropertyValue("ErrorCategory", ChartErrorCategory.STANDARD_DEVIATION);
 aProp.setPropertyValue("ErrorIndicator", ChartErrorIndicatorType.TOP_AND_BOTTOM);
Content on this page is licensed under the Public Documentation License (PDL).
Personal tools