Author: psteitz
Date: Sat Apr 16 14:49:45 2005
New Revision: 161613
URL: http://svn.apache.org/viewcvs?view=rev&rev=161613
Log:
Fixed javadoc errors. One-sided t-test significance adjustment was
reversed in javadoc for boolean-valued test methods.
BZ #34448
Reported by: Gilles Gaillard
Modified:
jakarta/commons/proper/math/trunk/src/java/org/apache/commons/math/stat/inference/TTest.java
jakarta/commons/proper/math/trunk/src/java/org/apache/commons/math/stat/inference/TTestImpl.java
jakarta/commons/proper/math/trunk/xdocs/userguide/stat.xml
Modified:
jakarta/commons/proper/math/trunk/src/java/org/apache/commons/math/stat/inference/TTest.java
URL:
http://svn.apache.org/viewcvs/jakarta/commons/proper/math/trunk/src/java/org/apache/commons/math/stat/inference/TTest.java?view=diff&r1=161612&r2=161613
==============================================================================
---
jakarta/commons/proper/math/trunk/src/java/org/apache/commons/math/stat/inference/TTest.java
(original)
+++
jakarta/commons/proper/math/trunk/src/java/org/apache/commons/math/stat/inference/TTest.java
Sat Apr 16 14:49:45 2005
@@ -110,7 +110,7 @@
* <p>
* Returns <code>true</code> iff the null hypothesis can be rejected with
* confidence <code>1 - alpha</code>. To perform a 1-sided test, use
- * <code>alpha / 2</code>
+ * <code>alpha * 2</code>
* <p>
* <strong>Usage Note:</strong><br>
* The validity of the test depends on the assumptions of the parametric
@@ -347,7 +347,7 @@
* <p>
* Returns <code>true</code> iff the null hypothesis can be
* rejected with confidence <code>1 - alpha</code>. To
- * perform a 1-sided test, use <code>alpha / 2</code>
+ * perform a 1-sided test, use <code>alpha * 2</code>
* <p>
* <strong>Examples:</strong><br><ol>
* <li>To test the (2-sided) hypothesis <code>sample mean = mu </code> at
@@ -356,7 +356,7 @@
* <li>To test the (one-sided) hypothesis <code> sample mean < mu </code>
* at the 99% level, first verify that the measured sample mean is less
* than <code>mu</code> and then use
- * <br><code>tTest(mu, sample, 0.005) </code>
+ * <br><code>tTest(mu, sample, 0.02) </code>
* </li></ol>
* <p>
* <strong>Usage Note:</strong><br>
@@ -415,7 +415,7 @@
* <p>
* Returns <code>true</code> iff the null hypothesis can be rejected with
* confidence <code>1 - alpha</code>. To perform a 1-sided test, use
- * <code>alpha / 2.</code>
+ * <code>alpha * 2.</code>
* <p>
* <strong>Examples:</strong><br><ol>
* <li>To test the (2-sided) hypothesis <code>sample mean = mu </code> at
@@ -424,7 +424,7 @@
* <li>To test the (one-sided) hypothesis <code> sample mean < mu </code>
* at the 99% level, first verify that the measured sample mean is less
* than <code>mu</code> and then use
- * <br><code>tTest(mu, sampleStats, 0.005) </code>
+ * <br><code>tTest(mu, sampleStats, 0.02) </code>
* </li></ol>
* <p>
* <strong>Usage Note:</strong><br>
@@ -535,7 +535,7 @@
* <p>
* Returns <code>true</code> iff the null hypothesis that the means are
* equal can be rejected with confidence <code>1 - alpha</code>. To
- * perform a 1-sided test, use <code>alpha / 2</code>
+ * perform a 1-sided test, use <code>alpha * 2</code>
* <p>
* See [EMAIL PROTECTED] #t(double[], double[])} for the formula used to
compute the
* t-statistic. Degrees of freedom are approximated using the
@@ -549,9 +549,9 @@
* <br><code>tTest(sample1, sample2, 0.05). </code>
* </li>
* <li>To test the (one-sided) hypothesis <code> mean 1 < mean 2 </code>,
- * first verify that the measured mean of <code>sample 1</code> is less
- * than the mean of <code>sample 2</code> and then use
- * <br><code>tTest(sample1, sample2, 0.005) </code>
+ * at the 99% level, first verify that the measured mean of <code>sample
1</code>
+ * is less than the mean of <code>sample 2</code> and then use
+ * <br><code>tTest(sample1, sample2, 0.02) </code>
* </li></ol>
* <p>
* <strong>Usage Note:</strong><br>
@@ -591,7 +591,7 @@
* <p>
* Returns <code>true</code> iff the null hypothesis that the means are
* equal can be rejected with confidence <code>1 - alpha</code>. To
- * perform a 1-sided test, use <code>alpha / 2.</code> To perform the test
+ * perform a 1-sided test, use <code>alpha * 2.</code> To perform the test
* without the assumption of equal subpopulation variances, use
* [EMAIL PROTECTED] #tTest(double[], double[], double)}.
* <p>
@@ -607,7 +607,7 @@
* at the 99% level, first verify that the measured mean of
* <code>sample 1</code> is less than the mean of <code>sample 2</code>
* and then use
- * <br><code>tTest(sample1, sample2, 0.005) </code>
+ * <br><code>tTest(sample1, sample2, 0.02) </code>
* </li></ol>
* <p>
* <strong>Usage Note:</strong><br>
@@ -723,7 +723,7 @@
* <p>
* Returns <code>true</code> iff the null hypothesis that the means are
* equal can be rejected with confidence <code>1 - alpha</code>. To
- * perform a 1-sided test, use <code>alpha / 2</code>
+ * perform a 1-sided test, use <code>alpha * 2</code>
* <p>
* See [EMAIL PROTECTED] #t(double[], double[])} for the formula used to
compute the
* t-statistic. Degrees of freedom are approximated using the
@@ -739,7 +739,7 @@
* at the 99% level, first verify that the measured mean of
* <code>sample 1</code> is less than the mean of <code>sample 2</code>
* and then use
- * <br><code>tTest(sampleStats1, sampleStats2, 0.005) </code>
+ * <br><code>tTest(sampleStats1, sampleStats2, 0.02) </code>
* </li></ol>
* <p>
* <strong>Usage Note:</strong><br>
Modified:
jakarta/commons/proper/math/trunk/src/java/org/apache/commons/math/stat/inference/TTestImpl.java
URL:
http://svn.apache.org/viewcvs/jakarta/commons/proper/math/trunk/src/java/org/apache/commons/math/stat/inference/TTestImpl.java?view=diff&r1=161612&r2=161613
==============================================================================
---
jakarta/commons/proper/math/trunk/src/java/org/apache/commons/math/stat/inference/TTestImpl.java
(original)
+++
jakarta/commons/proper/math/trunk/src/java/org/apache/commons/math/stat/inference/TTestImpl.java
Sat Apr 16 14:49:45 2005
@@ -123,7 +123,7 @@
* <p>
* Returns <code>true</code> iff the null hypothesis can be rejected with
* confidence <code>1 - alpha</code>. To perform a 1-sided test, use
- * <code>alpha / 2</code>
+ * <code>alpha * 2</code>
* <p>
* <strong>Usage Note:</strong><br>
* The validity of the test depends on the assumptions of the parametric
@@ -420,7 +420,7 @@
* <p>
* Returns <code>true</code> iff the null hypothesis can be
* rejected with confidence <code>1 - alpha</code>. To
- * perform a 1-sided test, use <code>alpha / 2</code>
+ * perform a 1-sided test, use <code>alpha * 2</code>
* <p>
* <strong>Examples:</strong><br><ol>
* <li>To test the (2-sided) hypothesis <code>sample mean = mu </code> at
@@ -429,7 +429,7 @@
* <li>To test the (one-sided) hypothesis <code> sample mean < mu </code>
* at the 99% level, first verify that the measured sample mean is less
* than <code>mu</code> and then use
- * <br><code>tTest(mu, sample, 0.005) </code>
+ * <br><code>tTest(mu, sample, 0.02) </code>
* </li></ol>
* <p>
* <strong>Usage Note:</strong><br>
@@ -501,7 +501,7 @@
* <p>
* Returns <code>true</code> iff the null hypothesis can be rejected with
* confidence <code>1 - alpha</code>. To perform a 1-sided test, use
- * <code>alpha / 2.</code>
+ * <code>alpha * 2.</code>
* <p>
* <strong>Examples:</strong><br><ol>
* <li>To test the (2-sided) hypothesis <code>sample mean = mu </code> at
@@ -510,7 +510,7 @@
* <li>To test the (one-sided) hypothesis <code> sample mean < mu </code>
* at the 99% level, first verify that the measured sample mean is less
* than <code>mu</code> and then use
- * <br><code>tTest(mu, sampleStats, 0.005) </code>
+ * <br><code>tTest(mu, sampleStats, 0.02) </code>
* </li></ol>
* <p>
* <strong>Usage Note:</strong><br>
@@ -656,10 +656,10 @@
* the 95% level, use
* <br><code>tTest(sample1, sample2, 0.05). </code>
* </li>
- * <li>To test the (one-sided) hypothesis <code> mean 1 < mean 2 </code>,
- * first verify that the measured mean of <code>sample 1</code> is less
- * than the mean of <code>sample 2</code> and then use
- * <br><code>tTest(sample1, sample2, 0.005) </code>
+ * <li>To test the (one-sided) hypothesis <code> mean 1 < mean 2 </code> at
+ * the 99% level, first verify that the measured mean of <code>sample
1</code>
+ * is less than the mean of <code>sample 2</code> and then use
+ * <br><code>tTest(sample1, sample2, 0.02) </code>
* </li></ol>
* <p>
* <strong>Usage Note:</strong><br>
@@ -703,7 +703,7 @@
* <p>
* Returns <code>true</code> iff the null hypothesis that the means are
* equal can be rejected with confidence <code>1 - alpha</code>. To
- * perform a 1-sided test, use <code>alpha / 2.</code> To perform the test
+ * perform a 1-sided test, use <code>alpha * 2.</code> To perform the test
* without the assumption of equal subpopulation variances, use
* [EMAIL PROTECTED] #tTest(double[], double[], double)}.
* <p>
@@ -719,7 +719,7 @@
* at the 99% level, first verify that the measured mean of
* <code>sample 1</code> is less than the mean of <code>sample 2</code>
* and then use
- * <br><code>tTest(sample1, sample2, 0.005) </code>
+ * <br><code>tTest(sample1, sample2, 0.02) </code>
* </li></ol>
* <p>
* <strong>Usage Note:</strong><br>
@@ -855,7 +855,7 @@
* <p>
* Returns <code>true</code> iff the null hypothesis that the means are
* equal can be rejected with confidence <code>1 - alpha</code>. To
- * perform a 1-sided test, use <code>alpha / 2</code>
+ * perform a 1-sided test, use <code>alpha * 2</code>
* <p>
* See [EMAIL PROTECTED] #t(double[], double[])} for the formula used to
compute the
* t-statistic. Degrees of freedom are approximated using the
@@ -871,7 +871,7 @@
* at the 99% level, first verify that the measured mean of
* <code>sample 1</code> is less than the mean of <code>sample 2</code>
* and then use
- * <br><code>tTest(sampleStats1, sampleStats2, 0.005) </code>
+ * <br><code>tTest(sampleStats1, sampleStats2, 0.02) </code>
* </li></ol>
* <p>
* <strong>Usage Note:</strong><br>
Modified: jakarta/commons/proper/math/trunk/xdocs/userguide/stat.xml
URL:
http://svn.apache.org/viewcvs/jakarta/commons/proper/math/trunk/xdocs/userguide/stat.xml?view=diff&r1=161612&r2=161613
==============================================================================
--- jakarta/commons/proper/math/trunk/xdocs/userguide/stat.xml (original)
+++ jakarta/commons/proper/math/trunk/xdocs/userguide/stat.xml Sat Apr 16
14:49:45 2005
@@ -500,7 +500,7 @@
</source>
</p>
<p>
- To compute the (one-sided) p-value:
+ To compute the p-value:
<source>
testStatistic.pairedTTest(sample1, sample2);
</source>
@@ -515,7 +515,7 @@
returned by <code>testStatistic.pairedTTest(sample1, sample2)</code>
is less than <code>.05</code>
</dd>
- <dd><strong>Example 2: </strong> unpaired, two-sample t-test using
+ <dd><strong>Example 2: </strong> unpaired, two-sided, two-sample
t-test using
<code>StatisticalSummary</code> instances, without assuming that
subpopulation variances are equal.
<p>
@@ -543,7 +543,7 @@
</source>
</p>
<p>
- To compute the (one-sided) p-value:
+ To compute the p-value:
<source>
testStatistic.tTest(sample1, sample2);
</source>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]