org.apache.ignite.ml.math.stat

## Class DistributionMixture<C extends Distribution>

- java.lang.Object
- - org.apache.ignite.ml.math.stat.DistributionMixture<C>

- Type Parameters:
    `C` - distributions mixture component class.
  All Implemented Interfaces:
    Serializable, Distribution
  Direct Known Subclasses:
    GmmModel

      public abstract class DistributionMixture<C extends Distribution>
      extends Object
      implements Distribution

  Mixture of distributions class where each component has own probability and probability of input vector can be computed as a sum of likelihoods of each component.
  See Also:
    Serialized Form

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `DistributionMixture()`
    `DistributionMixture(Vector componentProbs, List<C> distributions)` Creates an instance of DistributionMixture.

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `Vector` | `componentsProbs()`
    `int` | `countOfComponents()`
    `int` | `dimension()`
    `List<C>` | `distributions()`
    `Vector` | `likelihood(Vector x)`
    `double` | `prob(Vector x)`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### DistributionMixture

          public DistributionMixture(Vector componentProbs,
                                     List<C> distributions)

      Creates an instance of DistributionMixture.
      Parameters:
        `componentProbs` - Component probabilities.
        `distributions` - Distributions.

    - #### DistributionMixture

          public DistributionMixture()

  - ### Method Detail

    - #### prob

          public double prob(Vector x)

      Specified by:
        `prob` in interface `Distribution`
      Parameters:
        `x` - Vector.
      Returns:
        Probability of vector.

    - #### likelihood

          public Vector likelihood(Vector x)

      Parameters:
        `x` - Vector.
      Returns:
        Vector consists of likelihoods of each mixture components.

    - #### countOfComponents

          public int countOfComponents()

      Returns:
        An amount of components.

    - #### componentsProbs

          public Vector componentsProbs()

      Returns:
        Component probabilities.

    - #### distributions

          public List<C> distributions()

      Returns:
        List of components.

    - #### dimension

          public int dimension()

      Specified by:
        `dimension` in interface `Distribution`
      Returns:
        Dimension of vector space.

2022 Copyright © Apache Software Foundation
| Follow @ApacheIgnite
Ignite Database and Caching Platform | : ver. 2.12.0
Release Date | : January 10 2022