[Schmitzm-commits] r1206 - in trunk/src/schmitzm/jfree: . resource/locales
scm-commit@wald.intevation.org
scm-commit at wald.intevation.org
Wed Nov 3 00:48:08 CET 2010
Author: mojays
Date: 2010-11-03 00:48:07 +0100 (Wed, 03 Nov 2010)
New Revision: 1206
Modified:
trunk/src/schmitzm/jfree/JFreeChartUtil.java
trunk/src/schmitzm/jfree/resource/locales/JFreeResourceBundle.properties
trunk/src/schmitzm/jfree/resource/locales/JFreeResourceBundle_de.properties
Log:
Textual regression information tuned with nicer tooltips.
Modified: trunk/src/schmitzm/jfree/JFreeChartUtil.java
===================================================================
--- trunk/src/schmitzm/jfree/JFreeChartUtil.java 2010-11-02 23:12:18 UTC (rev 1205)
+++ trunk/src/schmitzm/jfree/JFreeChartUtil.java 2010-11-02 23:48:07 UTC (rev 1206)
@@ -1243,14 +1243,6 @@
// create and set the renderer for the regression line
XYLineAndShapeRenderer renderer = new XYLineAndShapeRenderer(true,
false);
- final String string = RESOURCE.getString("regressionline.tooltip");
- renderer.setLegendItemToolTipGenerator(new XYSeriesLabelGenerator() {
-
- @Override
- public String generateLabel(XYDataset dataset, int series) {
- return string;
- }
- });
renderer.setSeriesPaint(0, Color.blue);
plot.setRenderer(datasetCount, renderer);
}
@@ -1282,7 +1274,7 @@
regrInfoRStr += " (" + regressionData.getRQuality() + ")";
TextTitle regrInfoR = new TextTitle(regrInfoRStr, TextTitle.DEFAULT_FONT.deriveFont(Font.PLAIN) );
regrInfoR.setTextAlignment(HorizontalAlignment.LEFT);
- regrInfoR.setToolTipText(R("regressionInfo.data.r") + " = " + regressionData.getR() );
+ regrInfoR.setToolTipText(R("regressionInfo.data.r.tooltip",regressionData.getR()));
container.add(regrInfoR);
// Information text for N
@@ -1290,7 +1282,7 @@
regrInfoNStr += " = " + regressionData.getSampleCount();
TextTitle regrInfoN = new TextTitle(regrInfoNStr, TextTitle.DEFAULT_FONT.deriveFont(Font.PLAIN) );
regrInfoN.setTextAlignment(HorizontalAlignment.LEFT);
- regrInfoN.setToolTipText(R("regressionInfo.data.count") + " = " + regressionData.getSampleCount() );
+ regrInfoN.setToolTipText( R("regressionInfo.data.n.tooltip",regressionData.getSampleCount()) );
container.add(regrInfoN);
// Information text for the regression line formular
@@ -1301,9 +1293,10 @@
TextTitle regrInfoFormula = new TextTitle(regrInfoFormulaStr, TextTitle.DEFAULT_FONT.deriveFont(Font.PLAIN) );
regrInfoFormula.setTextAlignment(HorizontalAlignment.LEFT);
regrInfoFormula.setToolTipText(
- R("regressionInfo.data.slope") + " = " + regressionData.getRegressionLineSlope() +
- "; " +
- R("regressionInfo.data.intercept") + " = " + regressionData.getRegressionLineIntercept()
+ R("regressionInfo.data.formula.tooltip",
+ regressionData.getRegressionLineSlope(),
+ regressionData.getRegressionLineIntercept()
+ )
);
container.add(regrInfoFormula);
Modified: trunk/src/schmitzm/jfree/resource/locales/JFreeResourceBundle.properties
===================================================================
--- trunk/src/schmitzm/jfree/resource/locales/JFreeResourceBundle.properties 2010-11-02 23:12:18 UTC (rev 1205)
+++ trunk/src/schmitzm/jfree/resource/locales/JFreeResourceBundle.properties 2010-11-02 23:48:07 UTC (rev 1206)
@@ -92,14 +92,13 @@
regression.verystrong.neg=very strong negative relation
regression.total.neg=perfect negative relation
-regressionline.tooltip=<html><i>r</i> is the product-moment-correlation coefficient and gives information about how strong the variables are related.</html>
regressionInfo.title=Regression information
regressionInfo.data.r=r
+regressionInfo.data.r.tooltip=<html><i>r</i> = ${0}<br>is the product-moment-correlation coefficient and gives information about how strong the variables are related.</html>
regressionInfo.data.n=n
-regressionInfo.data.count=Number of samples in the regression
+regressionInfo.data.n.tooltip=<html><i>n</i> = ${0}<br>is the number of samples in the regression</html>
regressionInfo.data.formula=Formula (ax + b)
-regressionInfo.data.slope=Slope
-regressionInfo.data.intercept=Intercept
+regressionInfo.data.formula.tooltip=<html><i>ax + b</i> is the formula of the regression line with<br>Slope <i>a</i> = ${0}<br>Intercept <i>b</i> = ${1}</html>
Exception.noWeightAttributeDefinedforAWeightedAggregation=A weighted AggregationFunction is selected, but not artribute for weighting is selected.
Modified: trunk/src/schmitzm/jfree/resource/locales/JFreeResourceBundle_de.properties
===================================================================
--- trunk/src/schmitzm/jfree/resource/locales/JFreeResourceBundle_de.properties 2010-11-02 23:12:18 UTC (rev 1205)
+++ trunk/src/schmitzm/jfree/resource/locales/JFreeResourceBundle_de.properties 2010-11-02 23:48:07 UTC (rev 1206)
@@ -95,15 +95,14 @@
regression.verystrong.neg=sehr starker negativer Zusammenhang
regression.total.neg=vollkommener negativer Zusammenhang
-regressionline.tooltip=<html><i>r</i> ist der Produktmomentkorrelationskoefizient und sagt aus, wie stark zwei Variablen voneinander abh\u00E4ngen.
regressionInfo.title=Regressions-Daten
regressionInfo.data.r=r
+regressionInfo.data.r.tooltip=<html><i>r</i> = ${0}<br>ist der Produktmomentkorrelationskoefizient und sagt aus, wie stark zwei Variablen voneinander abh\u00E4ngen.
regressionInfo.data.n=n
-regressionInfo.data.count=Anzahl der Wertepaare in der Regression
+regressionInfo.data.n.tooltip=<html><i>n</i> = ${0}<br>ist die Anzahl der Wertepaare in der Regression</html>
regressionInfo.data.formula=Formel (ax + b)
-regressionInfo.data.slope=Steigung
-regressionInfo.data.intercept=Y-Abschnitt
+regressionInfo.data.formula.tooltip=<html><i>ax + b</i> ist die Gleichung der Regressionsgeraden<br>Steigung <i>a</i> = ${0}<br>Y-Abschnitt <i>b</i> = ${1}
Exception.noWeightAttributeDefinedforAWeightedAggregation=Eine gewichtete Aggregierungsfunktion ist ausgew\u00E4hlt, aber kein Attribut f\u00FCr die Gewichtung.
More information about the Schmitzm-commits
mailing list