Example #1
0
        private void DoFitGMM()
        {
            // Create a new Gaussian Mixture Model
            var gmm = new GaussianMixtureModel(this.k);

            // If available, initialize with k-means
            if (this.kmeans != null)
            {
                gmm.Initialize(this.kmeans);
            }

            // Compute the model
            gmm.Compute(this.mixture);

            // Classify all instances in mixture data
            var classifications = gmm.Gaussians.Nearest(this.mixture);

            // Draw the classifications
            this.UpdateGraph(classifications);
        }
Example #2
0
        private void btnCompute_Click(object sender, EventArgs e)
        {
            // Create a new Gaussian Mixture Model
            GaussianMixtureModel gmm = new GaussianMixtureModel(k);

            // If available, initialize with k-means
            if (kmeans != null)
            {
                gmm.Initialize(kmeans);
            }

            // Compute the model
            gmm.Compute(mixture);

            // Classify all instances in mixture data
            int[] classifications = gmm.Classify(mixture);

            // Draw the classifications
            updateGraph(classifications);
        }
        /// <summary>
        ///   Estimates Gaussian distributions from the data.
        /// </summary>
        ///
        private void btnCompute_Click(object sender, EventArgs e)
        {
            // Create a new Gaussian Mixture Model
            var gmm = new GaussianMixtureModel(k);

            // If available, initialize with k-means
            if (kmeans != null)
            {
                gmm.Initialize(kmeans);
            }

            // Compute the model
            GaussianClusterCollection clustering = gmm.Learn(observations);

            // Classify all instances in mixture data
            int[] classifications = clustering.Decide(observations);

            // Draw the classifications
            updateGraph(classifications);
        }
Example #4
0
        /// <summary>
        ///   Estimates Gaussian distributions from the data.
        /// </summary>
        /// 
        private void btnCompute_Click(object sender, EventArgs e)
        {
            // Create a new Gaussian Mixture Model
            GaussianMixtureModel gmm = new GaussianMixtureModel(k);

            // If available, initialize with k-means
            if (kmeans != null) gmm.Initialize(kmeans);

            // Compute the model
            gmm.Compute(mixture);

            // Classify all instances in mixture data
            int[] classifications = gmm.Gaussians.Nearest(mixture);

            // Draw the classifications
            updateGraph(classifications);
        }
Example #5
0
        /// <summary>
        ///   Estimates Gaussian distributions from the data.
        /// </summary>
        /// 
        private void btnCompute_Click(object sender, EventArgs e)
        {
            // Create a new Gaussian Mixture Model
            var gmm = new GaussianMixtureModel(k);

            // If available, initialize with k-means
            if (kmeans != null) 
                gmm.Initialize(kmeans);

            // Compute the model
            GaussianClusterCollection clustering = gmm.Learn(observations);

            // Classify all instances in mixture data
            int[] classifications = clustering.Decide(observations);

            // Draw the classifications
            updateGraph(classifications);
        }