Return-Path: X-Original-To: apmail-commons-commits-archive@minotaur.apache.org Delivered-To: apmail-commons-commits-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id AA98BFFE5 for ; Fri, 29 Mar 2013 04:27:01 +0000 (UTC) Received: (qmail 16775 invoked by uid 500); 29 Mar 2013 04:27:00 -0000 Delivered-To: apmail-commons-commits-archive@commons.apache.org Received: (qmail 16421 invoked by uid 500); 29 Mar 2013 04:26:59 -0000 Mailing-List: contact commits-help@commons.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@commons.apache.org Delivered-To: mailing list commits@commons.apache.org Received: (qmail 16369 invoked by uid 99); 29 Mar 2013 04:26:58 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 29 Mar 2013 04:26:58 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 29 Mar 2013 04:26:56 +0000 Received: from eris.apache.org (localhost [127.0.0.1]) by eris.apache.org (Postfix) with ESMTP id AAEB623889CB; Fri, 29 Mar 2013 04:26:36 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1462393 - /commons/proper/math/trunk/src/main/java/org/apache/commons/math3/distribution/fitting/MultivariateNormalMixtureExpectationMaximization.java Date: Fri, 29 Mar 2013 04:26:36 -0000 To: commits@commons.apache.org From: psteitz@apache.org X-Mailer: svnmailer-1.0.8-patched Message-Id: <20130329042636.AAEB623889CB@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Author: psteitz Date: Fri Mar 29 04:26:36 2013 New Revision: 1462393 URL: http://svn.apache.org/r1462393 Log: Made static fields static. Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math3/distribution/fitting/MultivariateNormalMixtureExpectationMaximization.java Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math3/distribution/fitting/MultivariateNormalMixtureExpectationMaximization.java URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math3/distribution/fitting/MultivariateNormalMixtureExpectationMaximization.java?rev=1462393&r1=1462392&r2=1462393&view=diff ============================================================================== --- commons/proper/math/trunk/src/main/java/org/apache/commons/math3/distribution/fitting/MultivariateNormalMixtureExpectationMaximization.java (original) +++ commons/proper/math/trunk/src/main/java/org/apache/commons/math3/distribution/fitting/MultivariateNormalMixtureExpectationMaximization.java Fri Mar 29 04:26:36 2013 @@ -53,6 +53,14 @@ import org.apache.commons.math3.util.Pai */ public class MultivariateNormalMixtureExpectationMaximization { /** + * Default maximum number of iterations allowed per fitting process. + */ + private static final int DEFAULT_MAX_ITERATIONS = 1000; + /** + * Default convergence threshold for fitting. + */ + private static final double DEFAULT_THRESHOLD = 1E-5; + /** * The data to fit. */ private final double[][] data; @@ -64,14 +72,6 @@ public class MultivariateNormalMixtureEx * The log likelihood of the data given the fitted model. */ private double logLikelihood = 0d; - /** - * Default maximum number of iterations allowed per fitting process. - */ - private final int defaultMaxIterations = 1000; - /** - * Default convergence threshold for fitting. - */ - private final double defaultThreshold = 1E-5; /** * Creates an object to fit a multivariate normal mixture model to data. @@ -278,7 +278,7 @@ public class MultivariateNormalMixtureEx public void fit(MixtureMultivariateNormalDistribution initialMixture) throws SingularMatrixException, NotStrictlyPositiveException { - fit(initialMixture, defaultMaxIterations, defaultThreshold); + fit(initialMixture, DEFAULT_MAX_ITERATIONS, DEFAULT_THRESHOLD); } /**