replaced calls to deprecated SummaryStatistics.newInstance() method

git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@610788 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Luc Maisonobe 2008-01-10 13:45:24 +00:00
parent 2b3e980421
commit dc04cc5690
1 changed files with 3 additions and 3 deletions

View File

@ -266,7 +266,7 @@ public class EmpiricalDistributionImpl implements Serializable, EmpiricalDistrib
public void computeStats() throws IOException {
String str = null;
double val = 0.0;
sampleStats = SummaryStatistics.newInstance();
sampleStats = new SummaryStatistics();
while ((str = inputStream.readLine()) != null) {
val = new Double(str).doubleValue();
sampleStats.addValue(val);
@ -299,7 +299,7 @@ public class EmpiricalDistributionImpl implements Serializable, EmpiricalDistrib
* @throws IOException if an IO error occurs
*/
public void computeStats() throws IOException {
sampleStats = SummaryStatistics.newInstance();
sampleStats = new SummaryStatistics();
for (int i = 0; i < inputArray.length; i++) {
sampleStats.addValue(inputArray[i]);
}
@ -345,7 +345,7 @@ public class EmpiricalDistributionImpl implements Serializable, EmpiricalDistrib
binStats.clear();
}
for (int i = 0; i < binCount; i++) {
SummaryStatistics stats = SummaryStatistics.newInstance();
SummaryStatistics stats = new SummaryStatistics();
binStats.add(i,stats);
}