commons-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From l..@apache.org
Subject svn commit: r948064 [37/38] - in /websites/production/commons/content/proper/commons-math/testapidocs: ./ org/apache/commons/math3/ org/apache/commons/math3/analysis/ org/apache/commons/math3/analysis/class-use/ org/apache/commons/math3/analysis/differ...
Date Fri, 17 Apr 2015 19:44:43 GMT
Modified: websites/production/commons/content/proper/commons-math/testapidocs/src-html/org/apache/commons/math3/stat/descriptive/SummaryStatisticsTest.html
==============================================================================
--- websites/production/commons/content/proper/commons-math/testapidocs/src-html/org/apache/commons/math3/stat/descriptive/SummaryStatisticsTest.html (original)
+++ websites/production/commons/content/proper/commons-math/testapidocs/src-html/org/apache/commons/math3/stat/descriptive/SummaryStatisticsTest.html Fri Apr 17 19:43:52 2015
@@ -36,333 +36,348 @@
 <span class="sourceLineNo">028</span>import org.junit.Test;<a name="line.28"></a>
 <span class="sourceLineNo">029</span>/**<a name="line.29"></a>
 <span class="sourceLineNo">030</span> * Test cases for the {@link SummaryStatistics} class.<a name="line.30"></a>
-<span class="sourceLineNo">031</span> *<a name="line.31"></a>
-<span class="sourceLineNo">032</span> */<a name="line.32"></a>
+<span class="sourceLineNo">031</span> */<a name="line.31"></a>
+<span class="sourceLineNo">032</span>public class SummaryStatisticsTest {<a name="line.32"></a>
 <span class="sourceLineNo">033</span><a name="line.33"></a>
-<span class="sourceLineNo">034</span>public class SummaryStatisticsTest {<a name="line.34"></a>
-<span class="sourceLineNo">035</span><a name="line.35"></a>
-<span class="sourceLineNo">036</span>    private double one = 1;<a name="line.36"></a>
-<span class="sourceLineNo">037</span>    private float twoF = 2;<a name="line.37"></a>
-<span class="sourceLineNo">038</span>    private long twoL = 2;<a name="line.38"></a>
-<span class="sourceLineNo">039</span>    private int three = 3;<a name="line.39"></a>
-<span class="sourceLineNo">040</span>    private double mean = 2;<a name="line.40"></a>
-<span class="sourceLineNo">041</span>    private double sumSq = 18;<a name="line.41"></a>
-<span class="sourceLineNo">042</span>    private double sum = 8;<a name="line.42"></a>
-<span class="sourceLineNo">043</span>    private double var = 0.666666666666666666667;<a name="line.43"></a>
-<span class="sourceLineNo">044</span>    private double popVar = 0.5;<a name="line.44"></a>
-<span class="sourceLineNo">045</span>    private double std = FastMath.sqrt(var);<a name="line.45"></a>
-<span class="sourceLineNo">046</span>    private double n = 4;<a name="line.46"></a>
-<span class="sourceLineNo">047</span>    private double min = 1;<a name="line.47"></a>
-<span class="sourceLineNo">048</span>    private double max = 3;<a name="line.48"></a>
-<span class="sourceLineNo">049</span>    private double tolerance = 10E-15;<a name="line.49"></a>
-<span class="sourceLineNo">050</span><a name="line.50"></a>
-<span class="sourceLineNo">051</span>    protected SummaryStatistics createSummaryStatistics() {<a name="line.51"></a>
-<span class="sourceLineNo">052</span>        return new SummaryStatistics();<a name="line.52"></a>
-<span class="sourceLineNo">053</span>    }<a name="line.53"></a>
-<span class="sourceLineNo">054</span><a name="line.54"></a>
-<span class="sourceLineNo">055</span>    /** test stats */<a name="line.55"></a>
-<span class="sourceLineNo">056</span>    @Test<a name="line.56"></a>
-<span class="sourceLineNo">057</span>    public void testStats() {<a name="line.57"></a>
-<span class="sourceLineNo">058</span>        SummaryStatistics u = createSummaryStatistics();<a name="line.58"></a>
-<span class="sourceLineNo">059</span>        Assert.assertEquals("total count",0,u.getN(),tolerance);<a name="line.59"></a>
-<span class="sourceLineNo">060</span>        u.addValue(one);<a name="line.60"></a>
-<span class="sourceLineNo">061</span>        u.addValue(twoF);<a name="line.61"></a>
-<span class="sourceLineNo">062</span>        u.addValue(twoL);<a name="line.62"></a>
-<span class="sourceLineNo">063</span>        u.addValue(three);<a name="line.63"></a>
-<span class="sourceLineNo">064</span>        Assert.assertEquals("N",n,u.getN(),tolerance);<a name="line.64"></a>
-<span class="sourceLineNo">065</span>        Assert.assertEquals("sum",sum,u.getSum(),tolerance);<a name="line.65"></a>
-<span class="sourceLineNo">066</span>        Assert.assertEquals("sumsq",sumSq,u.getSumsq(),tolerance);<a name="line.66"></a>
-<span class="sourceLineNo">067</span>        Assert.assertEquals("var",var,u.getVariance(),tolerance);<a name="line.67"></a>
-<span class="sourceLineNo">068</span>        Assert.assertEquals("population var",popVar,u.getPopulationVariance(),tolerance);<a name="line.68"></a>
-<span class="sourceLineNo">069</span>        Assert.assertEquals("std",std,u.getStandardDeviation(),tolerance);<a name="line.69"></a>
-<span class="sourceLineNo">070</span>        Assert.assertEquals("mean",mean,u.getMean(),tolerance);<a name="line.70"></a>
-<span class="sourceLineNo">071</span>        Assert.assertEquals("min",min,u.getMin(),tolerance);<a name="line.71"></a>
-<span class="sourceLineNo">072</span>        Assert.assertEquals("max",max,u.getMax(),tolerance);<a name="line.72"></a>
-<span class="sourceLineNo">073</span>        u.clear();<a name="line.73"></a>
-<span class="sourceLineNo">074</span>        Assert.assertEquals("total count",0,u.getN(),tolerance);<a name="line.74"></a>
-<span class="sourceLineNo">075</span>    }<a name="line.75"></a>
-<span class="sourceLineNo">076</span><a name="line.76"></a>
-<span class="sourceLineNo">077</span>    @Test<a name="line.77"></a>
-<span class="sourceLineNo">078</span>    public void testN0andN1Conditions() {<a name="line.78"></a>
-<span class="sourceLineNo">079</span>        SummaryStatistics u = createSummaryStatistics();<a name="line.79"></a>
-<span class="sourceLineNo">080</span>        Assert.assertTrue("Mean of n = 0 set should be NaN",<a name="line.80"></a>
-<span class="sourceLineNo">081</span>                Double.isNaN( u.getMean() ) );<a name="line.81"></a>
-<span class="sourceLineNo">082</span>        Assert.assertTrue("Standard Deviation of n = 0 set should be NaN",<a name="line.82"></a>
-<span class="sourceLineNo">083</span>                Double.isNaN( u.getStandardDeviation() ) );<a name="line.83"></a>
-<span class="sourceLineNo">084</span>        Assert.assertTrue("Variance of n = 0 set should be NaN",<a name="line.84"></a>
-<span class="sourceLineNo">085</span>                Double.isNaN(u.getVariance() ) );<a name="line.85"></a>
-<span class="sourceLineNo">086</span><a name="line.86"></a>
-<span class="sourceLineNo">087</span>        /* n=1 */<a name="line.87"></a>
-<span class="sourceLineNo">088</span>        u.addValue(one);<a name="line.88"></a>
-<span class="sourceLineNo">089</span>        Assert.assertTrue("mean should be one (n = 1)",<a name="line.89"></a>
-<span class="sourceLineNo">090</span>                u.getMean() == one);<a name="line.90"></a>
-<span class="sourceLineNo">091</span>        Assert.assertTrue("geometric should be one (n = 1) instead it is " + u.getGeometricMean(),<a name="line.91"></a>
-<span class="sourceLineNo">092</span>                u.getGeometricMean() == one);<a name="line.92"></a>
-<span class="sourceLineNo">093</span>        Assert.assertTrue("Std should be zero (n = 1)",<a name="line.93"></a>
-<span class="sourceLineNo">094</span>                u.getStandardDeviation() == 0.0);<a name="line.94"></a>
-<span class="sourceLineNo">095</span>        Assert.assertTrue("variance should be zero (n = 1)",<a name="line.95"></a>
-<span class="sourceLineNo">096</span>                u.getVariance() == 0.0);<a name="line.96"></a>
-<span class="sourceLineNo">097</span><a name="line.97"></a>
-<span class="sourceLineNo">098</span>        /* n=2 */<a name="line.98"></a>
-<span class="sourceLineNo">099</span>        u.addValue(twoF);<a name="line.99"></a>
-<span class="sourceLineNo">100</span>        Assert.assertTrue("Std should not be zero (n = 2)",<a name="line.100"></a>
-<span class="sourceLineNo">101</span>                u.getStandardDeviation() != 0.0);<a name="line.101"></a>
-<span class="sourceLineNo">102</span>        Assert.assertTrue("variance should not be zero (n = 2)",<a name="line.102"></a>
-<span class="sourceLineNo">103</span>                u.getVariance() != 0.0);<a name="line.103"></a>
+<span class="sourceLineNo">034</span>    private double one = 1;<a name="line.34"></a>
+<span class="sourceLineNo">035</span>    private float twoF = 2;<a name="line.35"></a>
+<span class="sourceLineNo">036</span>    private long twoL = 2;<a name="line.36"></a>
+<span class="sourceLineNo">037</span>    private int three = 3;<a name="line.37"></a>
+<span class="sourceLineNo">038</span>    private double mean = 2;<a name="line.38"></a>
+<span class="sourceLineNo">039</span>    private double sumSq = 18;<a name="line.39"></a>
+<span class="sourceLineNo">040</span>    private double sum = 8;<a name="line.40"></a>
+<span class="sourceLineNo">041</span>    private double var = 0.666666666666666666667;<a name="line.41"></a>
+<span class="sourceLineNo">042</span>    private double popVar = 0.5;<a name="line.42"></a>
+<span class="sourceLineNo">043</span>    private double std = FastMath.sqrt(var);<a name="line.43"></a>
+<span class="sourceLineNo">044</span>    private double n = 4;<a name="line.44"></a>
+<span class="sourceLineNo">045</span>    private double min = 1;<a name="line.45"></a>
+<span class="sourceLineNo">046</span>    private double max = 3;<a name="line.46"></a>
+<span class="sourceLineNo">047</span>    private double tolerance = 10E-15;<a name="line.47"></a>
+<span class="sourceLineNo">048</span><a name="line.48"></a>
+<span class="sourceLineNo">049</span>    protected SummaryStatistics createSummaryStatistics() {<a name="line.49"></a>
+<span class="sourceLineNo">050</span>        return new SummaryStatistics();<a name="line.50"></a>
+<span class="sourceLineNo">051</span>    }<a name="line.51"></a>
+<span class="sourceLineNo">052</span><a name="line.52"></a>
+<span class="sourceLineNo">053</span>    /** test stats */<a name="line.53"></a>
+<span class="sourceLineNo">054</span>    @Test<a name="line.54"></a>
+<span class="sourceLineNo">055</span>    public void testStats() {<a name="line.55"></a>
+<span class="sourceLineNo">056</span>        SummaryStatistics u = createSummaryStatistics();<a name="line.56"></a>
+<span class="sourceLineNo">057</span>        Assert.assertEquals("total count",0,u.getN(),tolerance);<a name="line.57"></a>
+<span class="sourceLineNo">058</span>        u.addValue(one);<a name="line.58"></a>
+<span class="sourceLineNo">059</span>        u.addValue(twoF);<a name="line.59"></a>
+<span class="sourceLineNo">060</span>        u.addValue(twoL);<a name="line.60"></a>
+<span class="sourceLineNo">061</span>        u.addValue(three);<a name="line.61"></a>
+<span class="sourceLineNo">062</span>        Assert.assertEquals("N",n,u.getN(),tolerance);<a name="line.62"></a>
+<span class="sourceLineNo">063</span>        Assert.assertEquals("sum",sum,u.getSum(),tolerance);<a name="line.63"></a>
+<span class="sourceLineNo">064</span>        Assert.assertEquals("sumsq",sumSq,u.getSumsq(),tolerance);<a name="line.64"></a>
+<span class="sourceLineNo">065</span>        Assert.assertEquals("var",var,u.getVariance(),tolerance);<a name="line.65"></a>
+<span class="sourceLineNo">066</span>        Assert.assertEquals("population var",popVar,u.getPopulationVariance(),tolerance);<a name="line.66"></a>
+<span class="sourceLineNo">067</span>        Assert.assertEquals("std",std,u.getStandardDeviation(),tolerance);<a name="line.67"></a>
+<span class="sourceLineNo">068</span>        Assert.assertEquals("mean",mean,u.getMean(),tolerance);<a name="line.68"></a>
+<span class="sourceLineNo">069</span>        Assert.assertEquals("min",min,u.getMin(),tolerance);<a name="line.69"></a>
+<span class="sourceLineNo">070</span>        Assert.assertEquals("max",max,u.getMax(),tolerance);<a name="line.70"></a>
+<span class="sourceLineNo">071</span>        u.clear();<a name="line.71"></a>
+<span class="sourceLineNo">072</span>        Assert.assertEquals("total count",0,u.getN(),tolerance);<a name="line.72"></a>
+<span class="sourceLineNo">073</span>    }<a name="line.73"></a>
+<span class="sourceLineNo">074</span><a name="line.74"></a>
+<span class="sourceLineNo">075</span>    @Test<a name="line.75"></a>
+<span class="sourceLineNo">076</span>    public void testN0andN1Conditions() {<a name="line.76"></a>
+<span class="sourceLineNo">077</span>        SummaryStatistics u = createSummaryStatistics();<a name="line.77"></a>
+<span class="sourceLineNo">078</span>        Assert.assertTrue("Mean of n = 0 set should be NaN",<a name="line.78"></a>
+<span class="sourceLineNo">079</span>                Double.isNaN( u.getMean() ) );<a name="line.79"></a>
+<span class="sourceLineNo">080</span>        Assert.assertTrue("Standard Deviation of n = 0 set should be NaN",<a name="line.80"></a>
+<span class="sourceLineNo">081</span>                Double.isNaN( u.getStandardDeviation() ) );<a name="line.81"></a>
+<span class="sourceLineNo">082</span>        Assert.assertTrue("Variance of n = 0 set should be NaN",<a name="line.82"></a>
+<span class="sourceLineNo">083</span>                Double.isNaN(u.getVariance() ) );<a name="line.83"></a>
+<span class="sourceLineNo">084</span><a name="line.84"></a>
+<span class="sourceLineNo">085</span>        /* n=1 */<a name="line.85"></a>
+<span class="sourceLineNo">086</span>        u.addValue(one);<a name="line.86"></a>
+<span class="sourceLineNo">087</span>        Assert.assertTrue("mean should be one (n = 1)",<a name="line.87"></a>
+<span class="sourceLineNo">088</span>                u.getMean() == one);<a name="line.88"></a>
+<span class="sourceLineNo">089</span>        Assert.assertTrue("geometric should be one (n = 1) instead it is " + u.getGeometricMean(),<a name="line.89"></a>
+<span class="sourceLineNo">090</span>                u.getGeometricMean() == one);<a name="line.90"></a>
+<span class="sourceLineNo">091</span>        Assert.assertTrue("Std should be zero (n = 1)",<a name="line.91"></a>
+<span class="sourceLineNo">092</span>                u.getStandardDeviation() == 0.0);<a name="line.92"></a>
+<span class="sourceLineNo">093</span>        Assert.assertTrue("variance should be zero (n = 1)",<a name="line.93"></a>
+<span class="sourceLineNo">094</span>                u.getVariance() == 0.0);<a name="line.94"></a>
+<span class="sourceLineNo">095</span><a name="line.95"></a>
+<span class="sourceLineNo">096</span>        /* n=2 */<a name="line.96"></a>
+<span class="sourceLineNo">097</span>        u.addValue(twoF);<a name="line.97"></a>
+<span class="sourceLineNo">098</span>        Assert.assertTrue("Std should not be zero (n = 2)",<a name="line.98"></a>
+<span class="sourceLineNo">099</span>                u.getStandardDeviation() != 0.0);<a name="line.99"></a>
+<span class="sourceLineNo">100</span>        Assert.assertTrue("variance should not be zero (n = 2)",<a name="line.100"></a>
+<span class="sourceLineNo">101</span>                u.getVariance() != 0.0);<a name="line.101"></a>
+<span class="sourceLineNo">102</span><a name="line.102"></a>
+<span class="sourceLineNo">103</span>    }<a name="line.103"></a>
 <span class="sourceLineNo">104</span><a name="line.104"></a>
-<span class="sourceLineNo">105</span>    }<a name="line.105"></a>
-<span class="sourceLineNo">106</span><a name="line.106"></a>
-<span class="sourceLineNo">107</span>    @Test<a name="line.107"></a>
-<span class="sourceLineNo">108</span>    public void testProductAndGeometricMean() {<a name="line.108"></a>
-<span class="sourceLineNo">109</span>        SummaryStatistics u = createSummaryStatistics();<a name="line.109"></a>
-<span class="sourceLineNo">110</span>        u.addValue( 1.0 );<a name="line.110"></a>
-<span class="sourceLineNo">111</span>        u.addValue( 2.0 );<a name="line.111"></a>
-<span class="sourceLineNo">112</span>        u.addValue( 3.0 );<a name="line.112"></a>
-<span class="sourceLineNo">113</span>        u.addValue( 4.0 );<a name="line.113"></a>
-<span class="sourceLineNo">114</span><a name="line.114"></a>
-<span class="sourceLineNo">115</span>        Assert.assertEquals( "Geometric mean not expected", 2.213364,<a name="line.115"></a>
-<span class="sourceLineNo">116</span>                u.getGeometricMean(), 0.00001 );<a name="line.116"></a>
-<span class="sourceLineNo">117</span>    }<a name="line.117"></a>
-<span class="sourceLineNo">118</span><a name="line.118"></a>
-<span class="sourceLineNo">119</span>    @Test<a name="line.119"></a>
-<span class="sourceLineNo">120</span>    public void testNaNContracts() {<a name="line.120"></a>
-<span class="sourceLineNo">121</span>        SummaryStatistics u = createSummaryStatistics();<a name="line.121"></a>
-<span class="sourceLineNo">122</span>        Assert.assertTrue("mean not NaN",Double.isNaN(u.getMean()));<a name="line.122"></a>
-<span class="sourceLineNo">123</span>        Assert.assertTrue("min not NaN",Double.isNaN(u.getMin()));<a name="line.123"></a>
-<span class="sourceLineNo">124</span>        Assert.assertTrue("std dev not NaN",Double.isNaN(u.getStandardDeviation()));<a name="line.124"></a>
-<span class="sourceLineNo">125</span>        Assert.assertTrue("var not NaN",Double.isNaN(u.getVariance()));<a name="line.125"></a>
-<span class="sourceLineNo">126</span>        Assert.assertTrue("geom mean not NaN",Double.isNaN(u.getGeometricMean()));<a name="line.126"></a>
+<span class="sourceLineNo">105</span>    @Test<a name="line.105"></a>
+<span class="sourceLineNo">106</span>    public void testProductAndGeometricMean() {<a name="line.106"></a>
+<span class="sourceLineNo">107</span>        SummaryStatistics u = createSummaryStatistics();<a name="line.107"></a>
+<span class="sourceLineNo">108</span>        u.addValue( 1.0 );<a name="line.108"></a>
+<span class="sourceLineNo">109</span>        u.addValue( 2.0 );<a name="line.109"></a>
+<span class="sourceLineNo">110</span>        u.addValue( 3.0 );<a name="line.110"></a>
+<span class="sourceLineNo">111</span>        u.addValue( 4.0 );<a name="line.111"></a>
+<span class="sourceLineNo">112</span><a name="line.112"></a>
+<span class="sourceLineNo">113</span>        Assert.assertEquals( "Geometric mean not expected", 2.213364,<a name="line.113"></a>
+<span class="sourceLineNo">114</span>                u.getGeometricMean(), 0.00001 );<a name="line.114"></a>
+<span class="sourceLineNo">115</span>    }<a name="line.115"></a>
+<span class="sourceLineNo">116</span><a name="line.116"></a>
+<span class="sourceLineNo">117</span>    @Test<a name="line.117"></a>
+<span class="sourceLineNo">118</span>    public void testNaNContracts() {<a name="line.118"></a>
+<span class="sourceLineNo">119</span>        SummaryStatistics u = createSummaryStatistics();<a name="line.119"></a>
+<span class="sourceLineNo">120</span>        Assert.assertTrue("mean not NaN",Double.isNaN(u.getMean()));<a name="line.120"></a>
+<span class="sourceLineNo">121</span>        Assert.assertTrue("min not NaN",Double.isNaN(u.getMin()));<a name="line.121"></a>
+<span class="sourceLineNo">122</span>        Assert.assertTrue("std dev not NaN",Double.isNaN(u.getStandardDeviation()));<a name="line.122"></a>
+<span class="sourceLineNo">123</span>        Assert.assertTrue("var not NaN",Double.isNaN(u.getVariance()));<a name="line.123"></a>
+<span class="sourceLineNo">124</span>        Assert.assertTrue("geom mean not NaN",Double.isNaN(u.getGeometricMean()));<a name="line.124"></a>
+<span class="sourceLineNo">125</span><a name="line.125"></a>
+<span class="sourceLineNo">126</span>        u.addValue(1.0);<a name="line.126"></a>
 <span class="sourceLineNo">127</span><a name="line.127"></a>
-<span class="sourceLineNo">128</span>        u.addValue(1.0);<a name="line.128"></a>
-<span class="sourceLineNo">129</span><a name="line.129"></a>
-<span class="sourceLineNo">130</span>        Assert.assertEquals( "mean not expected", 1.0,<a name="line.130"></a>
-<span class="sourceLineNo">131</span>                u.getMean(), Double.MIN_VALUE);<a name="line.131"></a>
-<span class="sourceLineNo">132</span>        Assert.assertEquals( "variance not expected", 0.0,<a name="line.132"></a>
-<span class="sourceLineNo">133</span>                u.getVariance(), Double.MIN_VALUE);<a name="line.133"></a>
-<span class="sourceLineNo">134</span>        Assert.assertEquals( "geometric mean not expected", 1.0,<a name="line.134"></a>
-<span class="sourceLineNo">135</span>                u.getGeometricMean(), Double.MIN_VALUE);<a name="line.135"></a>
+<span class="sourceLineNo">128</span>        Assert.assertEquals( "mean not expected", 1.0,<a name="line.128"></a>
+<span class="sourceLineNo">129</span>                u.getMean(), Double.MIN_VALUE);<a name="line.129"></a>
+<span class="sourceLineNo">130</span>        Assert.assertEquals( "variance not expected", 0.0,<a name="line.130"></a>
+<span class="sourceLineNo">131</span>                u.getVariance(), Double.MIN_VALUE);<a name="line.131"></a>
+<span class="sourceLineNo">132</span>        Assert.assertEquals( "geometric mean not expected", 1.0,<a name="line.132"></a>
+<span class="sourceLineNo">133</span>                u.getGeometricMean(), Double.MIN_VALUE);<a name="line.133"></a>
+<span class="sourceLineNo">134</span><a name="line.134"></a>
+<span class="sourceLineNo">135</span>        u.addValue(-1.0);<a name="line.135"></a>
 <span class="sourceLineNo">136</span><a name="line.136"></a>
-<span class="sourceLineNo">137</span>        u.addValue(-1.0);<a name="line.137"></a>
+<span class="sourceLineNo">137</span>        Assert.assertTrue("geom mean not NaN",Double.isNaN(u.getGeometricMean()));<a name="line.137"></a>
 <span class="sourceLineNo">138</span><a name="line.138"></a>
-<span class="sourceLineNo">139</span>        Assert.assertTrue("geom mean not NaN",Double.isNaN(u.getGeometricMean()));<a name="line.139"></a>
+<span class="sourceLineNo">139</span>        u.addValue(0.0);<a name="line.139"></a>
 <span class="sourceLineNo">140</span><a name="line.140"></a>
-<span class="sourceLineNo">141</span>        u.addValue(0.0);<a name="line.141"></a>
+<span class="sourceLineNo">141</span>        Assert.assertTrue("geom mean not NaN",Double.isNaN(u.getGeometricMean()));<a name="line.141"></a>
 <span class="sourceLineNo">142</span><a name="line.142"></a>
-<span class="sourceLineNo">143</span>        Assert.assertTrue("geom mean not NaN",Double.isNaN(u.getGeometricMean()));<a name="line.143"></a>
-<span class="sourceLineNo">144</span><a name="line.144"></a>
-<span class="sourceLineNo">145</span>        //FiXME: test all other NaN contract specs<a name="line.145"></a>
-<span class="sourceLineNo">146</span>    }<a name="line.146"></a>
-<span class="sourceLineNo">147</span><a name="line.147"></a>
-<span class="sourceLineNo">148</span>    @Test<a name="line.148"></a>
-<span class="sourceLineNo">149</span>    public void testGetSummary() {<a name="line.149"></a>
-<span class="sourceLineNo">150</span>        SummaryStatistics u = createSummaryStatistics();<a name="line.150"></a>
-<span class="sourceLineNo">151</span>        StatisticalSummary summary = u.getSummary();<a name="line.151"></a>
-<span class="sourceLineNo">152</span>        verifySummary(u, summary);<a name="line.152"></a>
-<span class="sourceLineNo">153</span>        u.addValue(1d);<a name="line.153"></a>
-<span class="sourceLineNo">154</span>        summary = u.getSummary();<a name="line.154"></a>
-<span class="sourceLineNo">155</span>        verifySummary(u, summary);<a name="line.155"></a>
-<span class="sourceLineNo">156</span>        u.addValue(2d);<a name="line.156"></a>
-<span class="sourceLineNo">157</span>        summary = u.getSummary();<a name="line.157"></a>
-<span class="sourceLineNo">158</span>        verifySummary(u, summary);<a name="line.158"></a>
-<span class="sourceLineNo">159</span>        u.addValue(2d);<a name="line.159"></a>
-<span class="sourceLineNo">160</span>        summary = u.getSummary();<a name="line.160"></a>
-<span class="sourceLineNo">161</span>        verifySummary(u, summary);<a name="line.161"></a>
-<span class="sourceLineNo">162</span>    }<a name="line.162"></a>
-<span class="sourceLineNo">163</span><a name="line.163"></a>
-<span class="sourceLineNo">164</span>    @Test<a name="line.164"></a>
-<span class="sourceLineNo">165</span>    public void testSerialization() {<a name="line.165"></a>
-<span class="sourceLineNo">166</span>        SummaryStatistics u = createSummaryStatistics();<a name="line.166"></a>
-<span class="sourceLineNo">167</span>        // Empty test<a name="line.167"></a>
-<span class="sourceLineNo">168</span>        TestUtils.checkSerializedEquality(u);<a name="line.168"></a>
-<span class="sourceLineNo">169</span>        SummaryStatistics s = (SummaryStatistics) TestUtils.serializeAndRecover(u);<a name="line.169"></a>
-<span class="sourceLineNo">170</span>        StatisticalSummary summary = s.getSummary();<a name="line.170"></a>
-<span class="sourceLineNo">171</span>        verifySummary(u, summary);<a name="line.171"></a>
-<span class="sourceLineNo">172</span><a name="line.172"></a>
-<span class="sourceLineNo">173</span>        // Add some data<a name="line.173"></a>
-<span class="sourceLineNo">174</span>        u.addValue(2d);<a name="line.174"></a>
-<span class="sourceLineNo">175</span>        u.addValue(1d);<a name="line.175"></a>
-<span class="sourceLineNo">176</span>        u.addValue(3d);<a name="line.176"></a>
-<span class="sourceLineNo">177</span>        u.addValue(4d);<a name="line.177"></a>
-<span class="sourceLineNo">178</span>        u.addValue(5d);<a name="line.178"></a>
-<span class="sourceLineNo">179</span><a name="line.179"></a>
-<span class="sourceLineNo">180</span>        // Test again<a name="line.180"></a>
-<span class="sourceLineNo">181</span>        TestUtils.checkSerializedEquality(u);<a name="line.181"></a>
-<span class="sourceLineNo">182</span>        s = (SummaryStatistics) TestUtils.serializeAndRecover(u);<a name="line.182"></a>
-<span class="sourceLineNo">183</span>        summary = s.getSummary();<a name="line.183"></a>
-<span class="sourceLineNo">184</span>        verifySummary(u, summary);<a name="line.184"></a>
+<span class="sourceLineNo">143</span>        //FiXME: test all other NaN contract specs<a name="line.143"></a>
+<span class="sourceLineNo">144</span>    }<a name="line.144"></a>
+<span class="sourceLineNo">145</span><a name="line.145"></a>
+<span class="sourceLineNo">146</span>    @Test<a name="line.146"></a>
+<span class="sourceLineNo">147</span>    public void testGetSummary() {<a name="line.147"></a>
+<span class="sourceLineNo">148</span>        SummaryStatistics u = createSummaryStatistics();<a name="line.148"></a>
+<span class="sourceLineNo">149</span>        StatisticalSummary summary = u.getSummary();<a name="line.149"></a>
+<span class="sourceLineNo">150</span>        verifySummary(u, summary);<a name="line.150"></a>
+<span class="sourceLineNo">151</span>        u.addValue(1d);<a name="line.151"></a>
+<span class="sourceLineNo">152</span>        summary = u.getSummary();<a name="line.152"></a>
+<span class="sourceLineNo">153</span>        verifySummary(u, summary);<a name="line.153"></a>
+<span class="sourceLineNo">154</span>        u.addValue(2d);<a name="line.154"></a>
+<span class="sourceLineNo">155</span>        summary = u.getSummary();<a name="line.155"></a>
+<span class="sourceLineNo">156</span>        verifySummary(u, summary);<a name="line.156"></a>
+<span class="sourceLineNo">157</span>        u.addValue(2d);<a name="line.157"></a>
+<span class="sourceLineNo">158</span>        summary = u.getSummary();<a name="line.158"></a>
+<span class="sourceLineNo">159</span>        verifySummary(u, summary);<a name="line.159"></a>
+<span class="sourceLineNo">160</span>    }<a name="line.160"></a>
+<span class="sourceLineNo">161</span><a name="line.161"></a>
+<span class="sourceLineNo">162</span>    @Test<a name="line.162"></a>
+<span class="sourceLineNo">163</span>    public void testSerialization() {<a name="line.163"></a>
+<span class="sourceLineNo">164</span>        SummaryStatistics u = createSummaryStatistics();<a name="line.164"></a>
+<span class="sourceLineNo">165</span>        // Empty test<a name="line.165"></a>
+<span class="sourceLineNo">166</span>        TestUtils.checkSerializedEquality(u);<a name="line.166"></a>
+<span class="sourceLineNo">167</span>        SummaryStatistics s = (SummaryStatistics) TestUtils.serializeAndRecover(u);<a name="line.167"></a>
+<span class="sourceLineNo">168</span>        StatisticalSummary summary = s.getSummary();<a name="line.168"></a>
+<span class="sourceLineNo">169</span>        verifySummary(u, summary);<a name="line.169"></a>
+<span class="sourceLineNo">170</span><a name="line.170"></a>
+<span class="sourceLineNo">171</span>        // Add some data<a name="line.171"></a>
+<span class="sourceLineNo">172</span>        u.addValue(2d);<a name="line.172"></a>
+<span class="sourceLineNo">173</span>        u.addValue(1d);<a name="line.173"></a>
+<span class="sourceLineNo">174</span>        u.addValue(3d);<a name="line.174"></a>
+<span class="sourceLineNo">175</span>        u.addValue(4d);<a name="line.175"></a>
+<span class="sourceLineNo">176</span>        u.addValue(5d);<a name="line.176"></a>
+<span class="sourceLineNo">177</span><a name="line.177"></a>
+<span class="sourceLineNo">178</span>        // Test again<a name="line.178"></a>
+<span class="sourceLineNo">179</span>        TestUtils.checkSerializedEquality(u);<a name="line.179"></a>
+<span class="sourceLineNo">180</span>        s = (SummaryStatistics) TestUtils.serializeAndRecover(u);<a name="line.180"></a>
+<span class="sourceLineNo">181</span>        summary = s.getSummary();<a name="line.181"></a>
+<span class="sourceLineNo">182</span>        verifySummary(u, summary);<a name="line.182"></a>
+<span class="sourceLineNo">183</span><a name="line.183"></a>
+<span class="sourceLineNo">184</span>    }<a name="line.184"></a>
 <span class="sourceLineNo">185</span><a name="line.185"></a>
-<span class="sourceLineNo">186</span>    }<a name="line.186"></a>
-<span class="sourceLineNo">187</span><a name="line.187"></a>
-<span class="sourceLineNo">188</span>    @Test<a name="line.188"></a>
-<span class="sourceLineNo">189</span>    public void testEqualsAndHashCode() {<a name="line.189"></a>
-<span class="sourceLineNo">190</span>        SummaryStatistics u = createSummaryStatistics();<a name="line.190"></a>
-<span class="sourceLineNo">191</span>        SummaryStatistics t = null;<a name="line.191"></a>
-<span class="sourceLineNo">192</span>        int emptyHash = u.hashCode();<a name="line.192"></a>
-<span class="sourceLineNo">193</span>        Assert.assertTrue("reflexive", u.equals(u));<a name="line.193"></a>
-<span class="sourceLineNo">194</span>        Assert.assertFalse("non-null compared to null", u.equals(t));<a name="line.194"></a>
-<span class="sourceLineNo">195</span>        Assert.assertFalse("wrong type", u.equals(Double.valueOf(0)));<a name="line.195"></a>
-<span class="sourceLineNo">196</span>        t = createSummaryStatistics();<a name="line.196"></a>
-<span class="sourceLineNo">197</span>        Assert.assertTrue("empty instances should be equal", t.equals(u));<a name="line.197"></a>
-<span class="sourceLineNo">198</span>        Assert.assertTrue("empty instances should be equal", u.equals(t));<a name="line.198"></a>
-<span class="sourceLineNo">199</span>        Assert.assertEquals("empty hash code", emptyHash, t.hashCode());<a name="line.199"></a>
-<span class="sourceLineNo">200</span><a name="line.200"></a>
-<span class="sourceLineNo">201</span>        // Add some data to u<a name="line.201"></a>
-<span class="sourceLineNo">202</span>        u.addValue(2d);<a name="line.202"></a>
-<span class="sourceLineNo">203</span>        u.addValue(1d);<a name="line.203"></a>
-<span class="sourceLineNo">204</span>        u.addValue(3d);<a name="line.204"></a>
-<span class="sourceLineNo">205</span>        u.addValue(4d);<a name="line.205"></a>
-<span class="sourceLineNo">206</span>        Assert.assertFalse("different n's should make instances not equal", t.equals(u));<a name="line.206"></a>
-<span class="sourceLineNo">207</span>        Assert.assertFalse("different n's should make instances not equal", u.equals(t));<a name="line.207"></a>
-<span class="sourceLineNo">208</span>        Assert.assertTrue("different n's should make hashcodes different",<a name="line.208"></a>
-<span class="sourceLineNo">209</span>                u.hashCode() != t.hashCode());<a name="line.209"></a>
-<span class="sourceLineNo">210</span><a name="line.210"></a>
-<span class="sourceLineNo">211</span>        //Add data in same order to t<a name="line.211"></a>
-<span class="sourceLineNo">212</span>        t.addValue(2d);<a name="line.212"></a>
-<span class="sourceLineNo">213</span>        t.addValue(1d);<a name="line.213"></a>
-<span class="sourceLineNo">214</span>        t.addValue(3d);<a name="line.214"></a>
-<span class="sourceLineNo">215</span>        t.addValue(4d);<a name="line.215"></a>
-<span class="sourceLineNo">216</span>        Assert.assertTrue("summaries based on same data should be equal", t.equals(u));<a name="line.216"></a>
-<span class="sourceLineNo">217</span>        Assert.assertTrue("summaries based on same data should be equal", u.equals(t));<a name="line.217"></a>
-<span class="sourceLineNo">218</span>        Assert.assertEquals("summaries based on same data should have same hashcodes",<a name="line.218"></a>
-<span class="sourceLineNo">219</span>                u.hashCode(), t.hashCode());<a name="line.219"></a>
-<span class="sourceLineNo">220</span><a name="line.220"></a>
-<span class="sourceLineNo">221</span>        // Clear and make sure summaries are indistinguishable from empty summary<a name="line.221"></a>
-<span class="sourceLineNo">222</span>        u.clear();<a name="line.222"></a>
-<span class="sourceLineNo">223</span>        t.clear();<a name="line.223"></a>
-<span class="sourceLineNo">224</span>        Assert.assertTrue("empty instances should be equal", t.equals(u));<a name="line.224"></a>
-<span class="sourceLineNo">225</span>        Assert.assertTrue("empty instances should be equal", u.equals(t));<a name="line.225"></a>
-<span class="sourceLineNo">226</span>        Assert.assertEquals("empty hash code", emptyHash, t.hashCode());<a name="line.226"></a>
-<span class="sourceLineNo">227</span>        Assert.assertEquals("empty hash code", emptyHash, u.hashCode());<a name="line.227"></a>
-<span class="sourceLineNo">228</span>    }<a name="line.228"></a>
-<span class="sourceLineNo">229</span><a name="line.229"></a>
-<span class="sourceLineNo">230</span>    @Test<a name="line.230"></a>
-<span class="sourceLineNo">231</span>    public void testCopy() {<a name="line.231"></a>
-<span class="sourceLineNo">232</span>        SummaryStatistics u = createSummaryStatistics();<a name="line.232"></a>
-<span class="sourceLineNo">233</span>        u.addValue(2d);<a name="line.233"></a>
-<span class="sourceLineNo">234</span>        u.addValue(1d);<a name="line.234"></a>
-<span class="sourceLineNo">235</span>        u.addValue(3d);<a name="line.235"></a>
-<span class="sourceLineNo">236</span>        u.addValue(4d);<a name="line.236"></a>
-<span class="sourceLineNo">237</span>        SummaryStatistics v = new SummaryStatistics(u);<a name="line.237"></a>
-<span class="sourceLineNo">238</span>        Assert.assertEquals(u, v);<a name="line.238"></a>
-<span class="sourceLineNo">239</span>        Assert.assertEquals(v, u);<a name="line.239"></a>
-<span class="sourceLineNo">240</span><a name="line.240"></a>
-<span class="sourceLineNo">241</span>        // Make sure both behave the same with additional values added<a name="line.241"></a>
-<span class="sourceLineNo">242</span>        u.addValue(7d);<a name="line.242"></a>
-<span class="sourceLineNo">243</span>        u.addValue(9d);<a name="line.243"></a>
-<span class="sourceLineNo">244</span>        u.addValue(11d);<a name="line.244"></a>
-<span class="sourceLineNo">245</span>        u.addValue(23d);<a name="line.245"></a>
-<span class="sourceLineNo">246</span>        v.addValue(7d);<a name="line.246"></a>
-<span class="sourceLineNo">247</span>        v.addValue(9d);<a name="line.247"></a>
-<span class="sourceLineNo">248</span>        v.addValue(11d);<a name="line.248"></a>
-<span class="sourceLineNo">249</span>        v.addValue(23d);<a name="line.249"></a>
-<span class="sourceLineNo">250</span>        Assert.assertEquals(u, v);<a name="line.250"></a>
-<span class="sourceLineNo">251</span>        Assert.assertEquals(v, u);<a name="line.251"></a>
-<span class="sourceLineNo">252</span><a name="line.252"></a>
-<span class="sourceLineNo">253</span>        // Check implementation pointers are preserved<a name="line.253"></a>
-<span class="sourceLineNo">254</span>        u.clear();<a name="line.254"></a>
-<span class="sourceLineNo">255</span>        u.setSumImpl(new Sum());<a name="line.255"></a>
-<span class="sourceLineNo">256</span>        SummaryStatistics.copy(u,v);<a name="line.256"></a>
-<span class="sourceLineNo">257</span>        Assert.assertEquals(u.getSumImpl(), v.getSumImpl());<a name="line.257"></a>
+<span class="sourceLineNo">186</span>    @Test<a name="line.186"></a>
+<span class="sourceLineNo">187</span>    public void testEqualsAndHashCode() {<a name="line.187"></a>
+<span class="sourceLineNo">188</span>        SummaryStatistics u = createSummaryStatistics();<a name="line.188"></a>
+<span class="sourceLineNo">189</span>        SummaryStatistics t = null;<a name="line.189"></a>
+<span class="sourceLineNo">190</span>        int emptyHash = u.hashCode();<a name="line.190"></a>
+<span class="sourceLineNo">191</span>        Assert.assertTrue("reflexive", u.equals(u));<a name="line.191"></a>
+<span class="sourceLineNo">192</span>        Assert.assertFalse("non-null compared to null", u.equals(t));<a name="line.192"></a>
+<span class="sourceLineNo">193</span>        Assert.assertFalse("wrong type", u.equals(Double.valueOf(0)));<a name="line.193"></a>
+<span class="sourceLineNo">194</span>        t = createSummaryStatistics();<a name="line.194"></a>
+<span class="sourceLineNo">195</span>        Assert.assertTrue("empty instances should be equal", t.equals(u));<a name="line.195"></a>
+<span class="sourceLineNo">196</span>        Assert.assertTrue("empty instances should be equal", u.equals(t));<a name="line.196"></a>
+<span class="sourceLineNo">197</span>        Assert.assertEquals("empty hash code", emptyHash, t.hashCode());<a name="line.197"></a>
+<span class="sourceLineNo">198</span><a name="line.198"></a>
+<span class="sourceLineNo">199</span>        // Add some data to u<a name="line.199"></a>
+<span class="sourceLineNo">200</span>        u.addValue(2d);<a name="line.200"></a>
+<span class="sourceLineNo">201</span>        u.addValue(1d);<a name="line.201"></a>
+<span class="sourceLineNo">202</span>        u.addValue(3d);<a name="line.202"></a>
+<span class="sourceLineNo">203</span>        u.addValue(4d);<a name="line.203"></a>
+<span class="sourceLineNo">204</span>        Assert.assertFalse("different n's should make instances not equal", t.equals(u));<a name="line.204"></a>
+<span class="sourceLineNo">205</span>        Assert.assertFalse("different n's should make instances not equal", u.equals(t));<a name="line.205"></a>
+<span class="sourceLineNo">206</span>        Assert.assertTrue("different n's should make hashcodes different",<a name="line.206"></a>
+<span class="sourceLineNo">207</span>                u.hashCode() != t.hashCode());<a name="line.207"></a>
+<span class="sourceLineNo">208</span><a name="line.208"></a>
+<span class="sourceLineNo">209</span>        //Add data in same order to t<a name="line.209"></a>
+<span class="sourceLineNo">210</span>        t.addValue(2d);<a name="line.210"></a>
+<span class="sourceLineNo">211</span>        t.addValue(1d);<a name="line.211"></a>
+<span class="sourceLineNo">212</span>        t.addValue(3d);<a name="line.212"></a>
+<span class="sourceLineNo">213</span>        t.addValue(4d);<a name="line.213"></a>
+<span class="sourceLineNo">214</span>        Assert.assertTrue("summaries based on same data should be equal", t.equals(u));<a name="line.214"></a>
+<span class="sourceLineNo">215</span>        Assert.assertTrue("summaries based on same data should be equal", u.equals(t));<a name="line.215"></a>
+<span class="sourceLineNo">216</span>        Assert.assertEquals("summaries based on same data should have same hashcodes",<a name="line.216"></a>
+<span class="sourceLineNo">217</span>                u.hashCode(), t.hashCode());<a name="line.217"></a>
+<span class="sourceLineNo">218</span><a name="line.218"></a>
+<span class="sourceLineNo">219</span>        // Clear and make sure summaries are indistinguishable from empty summary<a name="line.219"></a>
+<span class="sourceLineNo">220</span>        u.clear();<a name="line.220"></a>
+<span class="sourceLineNo">221</span>        t.clear();<a name="line.221"></a>
+<span class="sourceLineNo">222</span>        Assert.assertTrue("empty instances should be equal", t.equals(u));<a name="line.222"></a>
+<span class="sourceLineNo">223</span>        Assert.assertTrue("empty instances should be equal", u.equals(t));<a name="line.223"></a>
+<span class="sourceLineNo">224</span>        Assert.assertEquals("empty hash code", emptyHash, t.hashCode());<a name="line.224"></a>
+<span class="sourceLineNo">225</span>        Assert.assertEquals("empty hash code", emptyHash, u.hashCode());<a name="line.225"></a>
+<span class="sourceLineNo">226</span>    }<a name="line.226"></a>
+<span class="sourceLineNo">227</span><a name="line.227"></a>
+<span class="sourceLineNo">228</span>    @Test<a name="line.228"></a>
+<span class="sourceLineNo">229</span>    public void testCopy() {<a name="line.229"></a>
+<span class="sourceLineNo">230</span>        SummaryStatistics u = createSummaryStatistics();<a name="line.230"></a>
+<span class="sourceLineNo">231</span>        u.addValue(2d);<a name="line.231"></a>
+<span class="sourceLineNo">232</span>        u.addValue(1d);<a name="line.232"></a>
+<span class="sourceLineNo">233</span>        u.addValue(3d);<a name="line.233"></a>
+<span class="sourceLineNo">234</span>        u.addValue(4d);<a name="line.234"></a>
+<span class="sourceLineNo">235</span>        SummaryStatistics v = new SummaryStatistics(u);<a name="line.235"></a>
+<span class="sourceLineNo">236</span>        Assert.assertEquals(u, v);<a name="line.236"></a>
+<span class="sourceLineNo">237</span>        Assert.assertEquals(v, u);<a name="line.237"></a>
+<span class="sourceLineNo">238</span><a name="line.238"></a>
+<span class="sourceLineNo">239</span>        // Make sure both behave the same with additional values added<a name="line.239"></a>
+<span class="sourceLineNo">240</span>        u.addValue(7d);<a name="line.240"></a>
+<span class="sourceLineNo">241</span>        u.addValue(9d);<a name="line.241"></a>
+<span class="sourceLineNo">242</span>        u.addValue(11d);<a name="line.242"></a>
+<span class="sourceLineNo">243</span>        u.addValue(23d);<a name="line.243"></a>
+<span class="sourceLineNo">244</span>        v.addValue(7d);<a name="line.244"></a>
+<span class="sourceLineNo">245</span>        v.addValue(9d);<a name="line.245"></a>
+<span class="sourceLineNo">246</span>        v.addValue(11d);<a name="line.246"></a>
+<span class="sourceLineNo">247</span>        v.addValue(23d);<a name="line.247"></a>
+<span class="sourceLineNo">248</span>        Assert.assertEquals(u, v);<a name="line.248"></a>
+<span class="sourceLineNo">249</span>        Assert.assertEquals(v, u);<a name="line.249"></a>
+<span class="sourceLineNo">250</span><a name="line.250"></a>
+<span class="sourceLineNo">251</span>        // Check implementation pointers are preserved<a name="line.251"></a>
+<span class="sourceLineNo">252</span>        u.clear();<a name="line.252"></a>
+<span class="sourceLineNo">253</span>        u.setSumImpl(new Sum());<a name="line.253"></a>
+<span class="sourceLineNo">254</span>        SummaryStatistics.copy(u,v);<a name="line.254"></a>
+<span class="sourceLineNo">255</span>        Assert.assertEquals(u.getSumImpl(), v.getSumImpl());<a name="line.255"></a>
+<span class="sourceLineNo">256</span><a name="line.256"></a>
+<span class="sourceLineNo">257</span>    }<a name="line.257"></a>
 <span class="sourceLineNo">258</span><a name="line.258"></a>
-<span class="sourceLineNo">259</span>    }<a name="line.259"></a>
-<span class="sourceLineNo">260</span><a name="line.260"></a>
-<span class="sourceLineNo">261</span>    private void verifySummary(SummaryStatistics u, StatisticalSummary s) {<a name="line.261"></a>
-<span class="sourceLineNo">262</span>        Assert.assertEquals("N",s.getN(),u.getN());<a name="line.262"></a>
-<span class="sourceLineNo">263</span>        TestUtils.assertEquals("sum",s.getSum(),u.getSum(),tolerance);<a name="line.263"></a>
-<span class="sourceLineNo">264</span>        TestUtils.assertEquals("var",s.getVariance(),u.getVariance(),tolerance);<a name="line.264"></a>
-<span class="sourceLineNo">265</span>        TestUtils.assertEquals("std",s.getStandardDeviation(),u.getStandardDeviation(),tolerance);<a name="line.265"></a>
-<span class="sourceLineNo">266</span>        TestUtils.assertEquals("mean",s.getMean(),u.getMean(),tolerance);<a name="line.266"></a>
-<span class="sourceLineNo">267</span>        TestUtils.assertEquals("min",s.getMin(),u.getMin(),tolerance);<a name="line.267"></a>
-<span class="sourceLineNo">268</span>        TestUtils.assertEquals("max",s.getMax(),u.getMax(),tolerance);<a name="line.268"></a>
-<span class="sourceLineNo">269</span>    }<a name="line.269"></a>
-<span class="sourceLineNo">270</span><a name="line.270"></a>
-<span class="sourceLineNo">271</span>    @Test<a name="line.271"></a>
-<span class="sourceLineNo">272</span>    public void testSetterInjection() {<a name="line.272"></a>
-<span class="sourceLineNo">273</span>        SummaryStatistics u = createSummaryStatistics();<a name="line.273"></a>
-<span class="sourceLineNo">274</span>        u.setMeanImpl(new Sum());<a name="line.274"></a>
-<span class="sourceLineNo">275</span>        u.setSumLogImpl(new Sum());<a name="line.275"></a>
-<span class="sourceLineNo">276</span>        u.addValue(1);<a name="line.276"></a>
-<span class="sourceLineNo">277</span>        u.addValue(3);<a name="line.277"></a>
-<span class="sourceLineNo">278</span>        Assert.assertEquals(4, u.getMean(), 1E-14);<a name="line.278"></a>
-<span class="sourceLineNo">279</span>        Assert.assertEquals(4, u.getSumOfLogs(), 1E-14);<a name="line.279"></a>
-<span class="sourceLineNo">280</span>        Assert.assertEquals(FastMath.exp(2), u.getGeometricMean(), 1E-14);<a name="line.280"></a>
-<span class="sourceLineNo">281</span>        u.clear();<a name="line.281"></a>
-<span class="sourceLineNo">282</span>        u.addValue(1);<a name="line.282"></a>
-<span class="sourceLineNo">283</span>        u.addValue(2);<a name="line.283"></a>
-<span class="sourceLineNo">284</span>        Assert.assertEquals(3, u.getMean(), 1E-14);<a name="line.284"></a>
-<span class="sourceLineNo">285</span>        u.clear();<a name="line.285"></a>
-<span class="sourceLineNo">286</span>        u.setMeanImpl(new Mean()); // OK after clear<a name="line.286"></a>
-<span class="sourceLineNo">287</span>    }<a name="line.287"></a>
-<span class="sourceLineNo">288</span><a name="line.288"></a>
-<span class="sourceLineNo">289</span>    @Test<a name="line.289"></a>
-<span class="sourceLineNo">290</span>    public void testSetterIllegalState() {<a name="line.290"></a>
-<span class="sourceLineNo">291</span>        SummaryStatistics u = createSummaryStatistics();<a name="line.291"></a>
-<span class="sourceLineNo">292</span>        u.addValue(1);<a name="line.292"></a>
-<span class="sourceLineNo">293</span>        u.addValue(3);<a name="line.293"></a>
-<span class="sourceLineNo">294</span>        try {<a name="line.294"></a>
-<span class="sourceLineNo">295</span>            u.setMeanImpl(new Sum());<a name="line.295"></a>
-<span class="sourceLineNo">296</span>            Assert.fail("Expecting IllegalStateException");<a name="line.296"></a>
-<span class="sourceLineNo">297</span>        } catch (IllegalStateException ex) {<a name="line.297"></a>
-<span class="sourceLineNo">298</span>            // expected<a name="line.298"></a>
-<span class="sourceLineNo">299</span>        }<a name="line.299"></a>
-<span class="sourceLineNo">300</span>    }<a name="line.300"></a>
-<span class="sourceLineNo">301</span>    <a name="line.301"></a>
-<span class="sourceLineNo">302</span>    <a name="line.302"></a>
-<span class="sourceLineNo">303</span>    /**<a name="line.303"></a>
-<span class="sourceLineNo">304</span>     * JIRA: MATH-691<a name="line.304"></a>
-<span class="sourceLineNo">305</span>     */<a name="line.305"></a>
-<span class="sourceLineNo">306</span>    @Test<a name="line.306"></a>
-<span class="sourceLineNo">307</span>    public void testOverrideVarianceWithMathClass() {<a name="line.307"></a>
-<span class="sourceLineNo">308</span>        double[] scores = {1, 2, 3, 4};<a name="line.308"></a>
-<span class="sourceLineNo">309</span>        SummaryStatistics stats = new SummaryStatistics();<a name="line.309"></a>
-<span class="sourceLineNo">310</span>        stats.setVarianceImpl(new Variance(false)); //use "population variance"<a name="line.310"></a>
-<span class="sourceLineNo">311</span>        for(double i : scores) {<a name="line.311"></a>
-<span class="sourceLineNo">312</span>          stats.addValue(i);<a name="line.312"></a>
-<span class="sourceLineNo">313</span>        }<a name="line.313"></a>
-<span class="sourceLineNo">314</span>        Assert.assertEquals((new Variance(false)).evaluate(scores),stats.getVariance(), 0); <a name="line.314"></a>
-<span class="sourceLineNo">315</span>    }<a name="line.315"></a>
-<span class="sourceLineNo">316</span>    <a name="line.316"></a>
-<span class="sourceLineNo">317</span>    @Test<a name="line.317"></a>
-<span class="sourceLineNo">318</span>    public void testOverrideMeanWithMathClass() {<a name="line.318"></a>
-<span class="sourceLineNo">319</span>        double[] scores = {1, 2, 3, 4};<a name="line.319"></a>
-<span class="sourceLineNo">320</span>        SummaryStatistics stats = new SummaryStatistics();<a name="line.320"></a>
-<span class="sourceLineNo">321</span>        stats.setMeanImpl(new Mean()); <a name="line.321"></a>
-<span class="sourceLineNo">322</span>        for(double i : scores) {<a name="line.322"></a>
-<span class="sourceLineNo">323</span>          stats.addValue(i);<a name="line.323"></a>
-<span class="sourceLineNo">324</span>        }<a name="line.324"></a>
-<span class="sourceLineNo">325</span>        Assert.assertEquals((new Mean()).evaluate(scores),stats.getMean(), 0); <a name="line.325"></a>
-<span class="sourceLineNo">326</span>    }<a name="line.326"></a>
-<span class="sourceLineNo">327</span>    <a name="line.327"></a>
-<span class="sourceLineNo">328</span>    @Test<a name="line.328"></a>
-<span class="sourceLineNo">329</span>    public void testOverrideGeoMeanWithMathClass() {<a name="line.329"></a>
-<span class="sourceLineNo">330</span>        double[] scores = {1, 2, 3, 4};<a name="line.330"></a>
-<span class="sourceLineNo">331</span>        SummaryStatistics stats = new SummaryStatistics();<a name="line.331"></a>
-<span class="sourceLineNo">332</span>        stats.setGeoMeanImpl(new GeometricMean()); <a name="line.332"></a>
-<span class="sourceLineNo">333</span>        for(double i : scores) {<a name="line.333"></a>
-<span class="sourceLineNo">334</span>          stats.addValue(i);<a name="line.334"></a>
-<span class="sourceLineNo">335</span>        }<a name="line.335"></a>
-<span class="sourceLineNo">336</span>        Assert.assertEquals((new GeometricMean()).evaluate(scores),stats.getGeometricMean(), 0); <a name="line.336"></a>
-<span class="sourceLineNo">337</span>    }<a name="line.337"></a>
-<span class="sourceLineNo">338</span>    <a name="line.338"></a>
-<span class="sourceLineNo">339</span>    @Test<a name="line.339"></a>
-<span class="sourceLineNo">340</span>    public void testToString() {<a name="line.340"></a>
-<span class="sourceLineNo">341</span>        SummaryStatistics u = createSummaryStatistics();<a name="line.341"></a>
-<span class="sourceLineNo">342</span>        for (int i = 0; i &lt; 5; i++) {<a name="line.342"></a>
-<span class="sourceLineNo">343</span>                u.addValue(i);<a name="line.343"></a>
-<span class="sourceLineNo">344</span>        }<a name="line.344"></a>
-<span class="sourceLineNo">345</span>        final String[] labels = {"min", "max", "sum", "geometric mean", "variance",<a name="line.345"></a>
-<span class="sourceLineNo">346</span>                        "population variance", "second moment", "sum of squares", "standard deviation",<a name="line.346"></a>
-<span class="sourceLineNo">347</span>        "sum of logs"};<a name="line.347"></a>
-<span class="sourceLineNo">348</span>        final double[] values = {u.getMin(), u.getMax(), u.getSum(), u.getGeometricMean(),<a name="line.348"></a>
-<span class="sourceLineNo">349</span>                        u.getVariance(), u.getPopulationVariance(), u.getSecondMoment(), u.getSumsq(),<a name="line.349"></a>
-<span class="sourceLineNo">350</span>                        u.getStandardDeviation(), u.getSumOfLogs()};<a name="line.350"></a>
-<span class="sourceLineNo">351</span>        final String toString = u.toString();<a name="line.351"></a>
-<span class="sourceLineNo">352</span>        Assert.assertTrue(toString.indexOf("n: " + u.getN()) &gt; 0); // getN() returns a long<a name="line.352"></a>
-<span class="sourceLineNo">353</span>        for (int i = 0; i &lt; values.length; i++) {<a name="line.353"></a>
-<span class="sourceLineNo">354</span>                Assert.assertTrue(toString.indexOf(labels[i] + ": " + String.valueOf(values[i])) &gt; 0);<a name="line.354"></a>
-<span class="sourceLineNo">355</span>        }<a name="line.355"></a>
-<span class="sourceLineNo">356</span>    }<a name="line.356"></a>
-<span class="sourceLineNo">357</span>}<a name="line.357"></a>
+<span class="sourceLineNo">259</span>    private void verifySummary(SummaryStatistics u, StatisticalSummary s) {<a name="line.259"></a>
+<span class="sourceLineNo">260</span>        Assert.assertEquals("N",s.getN(),u.getN());<a name="line.260"></a>
+<span class="sourceLineNo">261</span>        TestUtils.assertEquals("sum",s.getSum(),u.getSum(),tolerance);<a name="line.261"></a>
+<span class="sourceLineNo">262</span>        TestUtils.assertEquals("var",s.getVariance(),u.getVariance(),tolerance);<a name="line.262"></a>
+<span class="sourceLineNo">263</span>        TestUtils.assertEquals("std",s.getStandardDeviation(),u.getStandardDeviation(),tolerance);<a name="line.263"></a>
+<span class="sourceLineNo">264</span>        TestUtils.assertEquals("mean",s.getMean(),u.getMean(),tolerance);<a name="line.264"></a>
+<span class="sourceLineNo">265</span>        TestUtils.assertEquals("min",s.getMin(),u.getMin(),tolerance);<a name="line.265"></a>
+<span class="sourceLineNo">266</span>        TestUtils.assertEquals("max",s.getMax(),u.getMax(),tolerance);<a name="line.266"></a>
+<span class="sourceLineNo">267</span>    }<a name="line.267"></a>
+<span class="sourceLineNo">268</span><a name="line.268"></a>
+<span class="sourceLineNo">269</span>    @Test<a name="line.269"></a>
+<span class="sourceLineNo">270</span>    public void testSetterInjection() {<a name="line.270"></a>
+<span class="sourceLineNo">271</span>        SummaryStatistics u = createSummaryStatistics();<a name="line.271"></a>
+<span class="sourceLineNo">272</span>        u.setMeanImpl(new Sum());<a name="line.272"></a>
+<span class="sourceLineNo">273</span>        u.setSumLogImpl(new Sum());<a name="line.273"></a>
+<span class="sourceLineNo">274</span>        u.addValue(1);<a name="line.274"></a>
+<span class="sourceLineNo">275</span>        u.addValue(3);<a name="line.275"></a>
+<span class="sourceLineNo">276</span>        Assert.assertEquals(4, u.getMean(), 1E-14);<a name="line.276"></a>
+<span class="sourceLineNo">277</span>        Assert.assertEquals(4, u.getSumOfLogs(), 1E-14);<a name="line.277"></a>
+<span class="sourceLineNo">278</span>        Assert.assertEquals(FastMath.exp(2), u.getGeometricMean(), 1E-14);<a name="line.278"></a>
+<span class="sourceLineNo">279</span>        u.clear();<a name="line.279"></a>
+<span class="sourceLineNo">280</span>        u.addValue(1);<a name="line.280"></a>
+<span class="sourceLineNo">281</span>        u.addValue(2);<a name="line.281"></a>
+<span class="sourceLineNo">282</span>        Assert.assertEquals(3, u.getMean(), 1E-14);<a name="line.282"></a>
+<span class="sourceLineNo">283</span>        u.clear();<a name="line.283"></a>
+<span class="sourceLineNo">284</span>        u.setMeanImpl(new Mean()); // OK after clear<a name="line.284"></a>
+<span class="sourceLineNo">285</span>    }<a name="line.285"></a>
+<span class="sourceLineNo">286</span><a name="line.286"></a>
+<span class="sourceLineNo">287</span>    @Test<a name="line.287"></a>
+<span class="sourceLineNo">288</span>    public void testSetterIllegalState() {<a name="line.288"></a>
+<span class="sourceLineNo">289</span>        SummaryStatistics u = createSummaryStatistics();<a name="line.289"></a>
+<span class="sourceLineNo">290</span>        u.addValue(1);<a name="line.290"></a>
+<span class="sourceLineNo">291</span>        u.addValue(3);<a name="line.291"></a>
+<span class="sourceLineNo">292</span>        try {<a name="line.292"></a>
+<span class="sourceLineNo">293</span>            u.setMeanImpl(new Sum());<a name="line.293"></a>
+<span class="sourceLineNo">294</span>            Assert.fail("Expecting IllegalStateException");<a name="line.294"></a>
+<span class="sourceLineNo">295</span>        } catch (IllegalStateException ex) {<a name="line.295"></a>
+<span class="sourceLineNo">296</span>            // expected<a name="line.296"></a>
+<span class="sourceLineNo">297</span>        }<a name="line.297"></a>
+<span class="sourceLineNo">298</span>    }<a name="line.298"></a>
+<span class="sourceLineNo">299</span>    <a name="line.299"></a>
+<span class="sourceLineNo">300</span>    @Test<a name="line.300"></a>
+<span class="sourceLineNo">301</span>    public void testQuadraticMean() {<a name="line.301"></a>
+<span class="sourceLineNo">302</span>        final double[] values = { 1.2, 3.4, 5.6, 7.89 };<a name="line.302"></a>
+<span class="sourceLineNo">303</span>        final SummaryStatistics stats = createSummaryStatistics();<a name="line.303"></a>
+<span class="sourceLineNo">304</span><a name="line.304"></a>
+<span class="sourceLineNo">305</span>        final int len = values.length;<a name="line.305"></a>
+<span class="sourceLineNo">306</span>        double expected = 0;<a name="line.306"></a>
+<span class="sourceLineNo">307</span>        for (int i = 0; i &lt; len; i++) {<a name="line.307"></a>
+<span class="sourceLineNo">308</span>            final double v = values[i];<a name="line.308"></a>
+<span class="sourceLineNo">309</span>            expected += v * v / len;<a name="line.309"></a>
+<span class="sourceLineNo">310</span><a name="line.310"></a>
+<span class="sourceLineNo">311</span>            stats.addValue(v);<a name="line.311"></a>
+<span class="sourceLineNo">312</span>        }<a name="line.312"></a>
+<span class="sourceLineNo">313</span>        expected = Math.sqrt(expected);<a name="line.313"></a>
+<span class="sourceLineNo">314</span><a name="line.314"></a>
+<span class="sourceLineNo">315</span>        Assert.assertEquals(expected, stats.getQuadraticMean(), Math.ulp(expected));<a name="line.315"></a>
+<span class="sourceLineNo">316</span>    }<a name="line.316"></a>
+<span class="sourceLineNo">317</span>    <a name="line.317"></a>
+<span class="sourceLineNo">318</span>    /**<a name="line.318"></a>
+<span class="sourceLineNo">319</span>     * JIRA: MATH-691<a name="line.319"></a>
+<span class="sourceLineNo">320</span>     */<a name="line.320"></a>
+<span class="sourceLineNo">321</span>    @Test<a name="line.321"></a>
+<span class="sourceLineNo">322</span>    public void testOverrideVarianceWithMathClass() {<a name="line.322"></a>
+<span class="sourceLineNo">323</span>        double[] scores = {1, 2, 3, 4};<a name="line.323"></a>
+<span class="sourceLineNo">324</span>        SummaryStatistics stats = new SummaryStatistics();<a name="line.324"></a>
+<span class="sourceLineNo">325</span>        stats.setVarianceImpl(new Variance(false)); //use "population variance"<a name="line.325"></a>
+<span class="sourceLineNo">326</span>        for(double i : scores) {<a name="line.326"></a>
+<span class="sourceLineNo">327</span>          stats.addValue(i);<a name="line.327"></a>
+<span class="sourceLineNo">328</span>        }<a name="line.328"></a>
+<span class="sourceLineNo">329</span>        Assert.assertEquals((new Variance(false)).evaluate(scores),stats.getVariance(), 0); <a name="line.329"></a>
+<span class="sourceLineNo">330</span>    }<a name="line.330"></a>
+<span class="sourceLineNo">331</span>    <a name="line.331"></a>
+<span class="sourceLineNo">332</span>    @Test<a name="line.332"></a>
+<span class="sourceLineNo">333</span>    public void testOverrideMeanWithMathClass() {<a name="line.333"></a>
+<span class="sourceLineNo">334</span>        double[] scores = {1, 2, 3, 4};<a name="line.334"></a>
+<span class="sourceLineNo">335</span>        SummaryStatistics stats = new SummaryStatistics();<a name="line.335"></a>
+<span class="sourceLineNo">336</span>        stats.setMeanImpl(new Mean()); <a name="line.336"></a>
+<span class="sourceLineNo">337</span>        for(double i : scores) {<a name="line.337"></a>
+<span class="sourceLineNo">338</span>          stats.addValue(i);<a name="line.338"></a>
+<span class="sourceLineNo">339</span>        }<a name="line.339"></a>
+<span class="sourceLineNo">340</span>        Assert.assertEquals((new Mean()).evaluate(scores),stats.getMean(), 0); <a name="line.340"></a>
+<span class="sourceLineNo">341</span>    }<a name="line.341"></a>
+<span class="sourceLineNo">342</span>    <a name="line.342"></a>
+<span class="sourceLineNo">343</span>    @Test<a name="line.343"></a>
+<span class="sourceLineNo">344</span>    public void testOverrideGeoMeanWithMathClass() {<a name="line.344"></a>
+<span class="sourceLineNo">345</span>        double[] scores = {1, 2, 3, 4};<a name="line.345"></a>
+<span class="sourceLineNo">346</span>        SummaryStatistics stats = new SummaryStatistics();<a name="line.346"></a>
+<span class="sourceLineNo">347</span>        stats.setGeoMeanImpl(new GeometricMean()); <a name="line.347"></a>
+<span class="sourceLineNo">348</span>        for(double i : scores) {<a name="line.348"></a>
+<span class="sourceLineNo">349</span>          stats.addValue(i);<a name="line.349"></a>
+<span class="sourceLineNo">350</span>        }<a name="line.350"></a>
+<span class="sourceLineNo">351</span>        Assert.assertEquals((new GeometricMean()).evaluate(scores),stats.getGeometricMean(), 0); <a name="line.351"></a>
+<span class="sourceLineNo">352</span>    }<a name="line.352"></a>
+<span class="sourceLineNo">353</span>    <a name="line.353"></a>
+<span class="sourceLineNo">354</span>    @Test<a name="line.354"></a>
+<span class="sourceLineNo">355</span>    public void testToString() {<a name="line.355"></a>
+<span class="sourceLineNo">356</span>        SummaryStatistics u = createSummaryStatistics();<a name="line.356"></a>
+<span class="sourceLineNo">357</span>        for (int i = 0; i &lt; 5; i++) {<a name="line.357"></a>
+<span class="sourceLineNo">358</span>            u.addValue(i);<a name="line.358"></a>
+<span class="sourceLineNo">359</span>        }<a name="line.359"></a>
+<span class="sourceLineNo">360</span>        final String[] labels = {"min", "max", "sum", "geometric mean", "variance",<a name="line.360"></a>
+<span class="sourceLineNo">361</span>                "population variance", "second moment", "sum of squares", "standard deviation",<a name="line.361"></a>
+<span class="sourceLineNo">362</span>        "sum of logs"};<a name="line.362"></a>
+<span class="sourceLineNo">363</span>        final double[] values = {u.getMin(), u.getMax(), u.getSum(), u.getGeometricMean(),<a name="line.363"></a>
+<span class="sourceLineNo">364</span>                u.getVariance(), u.getPopulationVariance(), u.getSecondMoment(), u.getSumsq(),<a name="line.364"></a>
+<span class="sourceLineNo">365</span>                u.getStandardDeviation(), u.getSumOfLogs()};<a name="line.365"></a>
+<span class="sourceLineNo">366</span>        final String toString = u.toString();<a name="line.366"></a>
+<span class="sourceLineNo">367</span>        Assert.assertTrue(toString.indexOf("n: " + u.getN()) &gt; 0); // getN() returns a long<a name="line.367"></a>
+<span class="sourceLineNo">368</span>        for (int i = 0; i &lt; values.length; i++) {<a name="line.368"></a>
+<span class="sourceLineNo">369</span>            Assert.assertTrue(toString.indexOf(labels[i] + ": " + String.valueOf(values[i])) &gt; 0);<a name="line.369"></a>
+<span class="sourceLineNo">370</span>        }<a name="line.370"></a>
+<span class="sourceLineNo">371</span>    }<a name="line.371"></a>
+<span class="sourceLineNo">372</span>}<a name="line.372"></a>
 
 
 

Modified: websites/production/commons/content/proper/commons-math/testapidocs/src-html/org/apache/commons/math3/stat/regression/OLSMultipleLinearRegressionTest.html
==============================================================================
--- websites/production/commons/content/proper/commons-math/testapidocs/src-html/org/apache/commons/math3/stat/regression/OLSMultipleLinearRegressionTest.html (original)
+++ websites/production/commons/content/proper/commons-math/testapidocs/src-html/org/apache/commons/math3/stat/regression/OLSMultipleLinearRegressionTest.html Fri Apr 17 19:43:52 2015
@@ -790,7 +790,42 @@
 <span class="sourceLineNo">782</span>        TestUtils.assertEquals(835542680000.000, model.calculateResidualSumOfSquares(), 1.0e-3);<a name="line.782"></a>
 <span class="sourceLineNo">783</span>        return;<a name="line.783"></a>
 <span class="sourceLineNo">784</span>    }<a name="line.784"></a>
-<span class="sourceLineNo">785</span>}<a name="line.785"></a>
+<span class="sourceLineNo">785</span>    <a name="line.785"></a>
+<span class="sourceLineNo">786</span>    /**<a name="line.786"></a>
+<span class="sourceLineNo">787</span>     * Anything requiring beta calculation should advertise SME.<a name="line.787"></a>
+<span class="sourceLineNo">788</span>     */<a name="line.788"></a>
+<span class="sourceLineNo">789</span>    @Test(expected=org.apache.commons.math3.linear.SingularMatrixException.class)<a name="line.789"></a>
+<span class="sourceLineNo">790</span>    public void testSingularCalculateBeta() {<a name="line.790"></a>
+<span class="sourceLineNo">791</span>        OLSMultipleLinearRegression model = new OLSMultipleLinearRegression();<a name="line.791"></a>
+<span class="sourceLineNo">792</span>        model.newSampleData(new double[] {1,  2,  3, 1, 2, 3, 1, 2, 3}, 3, 2);<a name="line.792"></a>
+<span class="sourceLineNo">793</span>        model.calculateBeta();<a name="line.793"></a>
+<span class="sourceLineNo">794</span>    }<a name="line.794"></a>
+<span class="sourceLineNo">795</span>    <a name="line.795"></a>
+<span class="sourceLineNo">796</span>    @Test<a name="line.796"></a>
+<span class="sourceLineNo">797</span>    public void testNoSSTOCalculateRsquare() {<a name="line.797"></a>
+<span class="sourceLineNo">798</span>        OLSMultipleLinearRegression model = new OLSMultipleLinearRegression();<a name="line.798"></a>
+<span class="sourceLineNo">799</span>        model.newSampleData(new double[] {1,  2,  3, 1, 7, 8, 1, 10, 12}, 3, 2);<a name="line.799"></a>
+<span class="sourceLineNo">800</span>        Assert.assertTrue(Double.isNaN(model.calculateRSquared()));<a name="line.800"></a>
+<span class="sourceLineNo">801</span>    }<a name="line.801"></a>
+<span class="sourceLineNo">802</span>    <a name="line.802"></a>
+<span class="sourceLineNo">803</span>    @Test(expected=NullPointerException.class)<a name="line.803"></a>
+<span class="sourceLineNo">804</span>    public void testNoDataNPECalculateBeta() {<a name="line.804"></a>
+<span class="sourceLineNo">805</span>        OLSMultipleLinearRegression model = new OLSMultipleLinearRegression();<a name="line.805"></a>
+<span class="sourceLineNo">806</span>        model.calculateBeta();<a name="line.806"></a>
+<span class="sourceLineNo">807</span>    }<a name="line.807"></a>
+<span class="sourceLineNo">808</span>    <a name="line.808"></a>
+<span class="sourceLineNo">809</span>    @Test(expected=NullPointerException.class)<a name="line.809"></a>
+<span class="sourceLineNo">810</span>    public void testNoDataNPECalculateHat() {<a name="line.810"></a>
+<span class="sourceLineNo">811</span>        OLSMultipleLinearRegression model = new OLSMultipleLinearRegression();<a name="line.811"></a>
+<span class="sourceLineNo">812</span>        model.calculateHat();<a name="line.812"></a>
+<span class="sourceLineNo">813</span>    }<a name="line.813"></a>
+<span class="sourceLineNo">814</span>    <a name="line.814"></a>
+<span class="sourceLineNo">815</span>    @Test(expected=NullPointerException.class)<a name="line.815"></a>
+<span class="sourceLineNo">816</span>    public void testNoDataNPESSTO() {<a name="line.816"></a>
+<span class="sourceLineNo">817</span>        OLSMultipleLinearRegression model = new OLSMultipleLinearRegression();<a name="line.817"></a>
+<span class="sourceLineNo">818</span>        model.calculateTotalSumOfSquares();<a name="line.818"></a>
+<span class="sourceLineNo">819</span>    }<a name="line.819"></a>
+<span class="sourceLineNo">820</span>}<a name="line.820"></a>
 
 
 



Mime
View raw message