GaussianMixtureProbabilityDensity.h
1 //-*-C++-*-
2 /***************************************************************************
3  *
4  * Copyright (C) 2022 by Willem van Straten
5  * Licensed under the Academic Free License version 2.1
6  *
7  ***************************************************************************/
8 
9 // psrchive/More/General/GaussianMixtureProbabilityDensity.h
10 
11 #include "BinaryStatistic.h"
12 #include "ndArray.h"
13 
14 #include <armadillo>
15 
16 namespace BinaryStatistics
17 {
18  class GeneralizedChiSquared;
19 
21 
22  class GaussianMixtureProbabilityDensity : public BinaryStatistic
23  {
24 
25  public:
26 
29 
30  arma::gmm_diag* model;
31 
32  GaussianMixtureProbabilityDensity ();
33 
34  double get (const std::vector<double>&, const std::vector<double>&);
35 
37  unsigned get_ngaus () const;
38 
40  { return new GaussianMixtureProbabilityDensity; }
41 
42  };
43 }
Reference::To< GeneralizedChiSquared > gcs
Optionally compute the GM psd of the principal component residuals.
Definition: GaussianMixtureProbabilityDensity.h:33
double get(const std::vector< double > &, const std::vector< double > &)
Derived types define the value returned.
Definition: GaussianMixtureProbabilityDensity.C:31
Template class manages Reference::Able objects.
Definition: Reference.h:74
Computes the Gaussian mixture probability density of the difference.
Definition: GaussianMixtureProbabilityDensity.h:27
GaussianMixtureProbabilityDensity * clone() const
Derived types must also define clone method.
Definition: GaussianMixtureProbabilityDensity.h:44
unsigned get_ngaus() const
Return the number of Gaussians.
Definition: GaussianMixtureProbabilityDensity.C:23
Commmon statistics that can be derived from two arrays of floats.
Definition: BinaryStatistic.h:17

Generated using doxygen 1.8.17