Multivariate Analysis Package  0.3
A multivariate distributions analysis package
 All Classes Namespaces Functions Pages
tCopula.h
1 #ifndef tCopula_h__
2 #define tCopula_h__
3 #include "AbsaractCopula.h"
4 #include "tDist.h"
5 namespace Multivariate{
7 
45  class tCopula : public AbstarctCopula{
46  private:
47  tDistribution *LocalVersion;
48  public:
50 
58  tCopula(unsigned int Dimension=2U, unsigned int DegFreedom=1U){BaseDist=new tDistribution(Dimension,DegFreedom); LocalVersion=static_cast<tDistribution*>(BaseDist);}
60 
78  tCopula(unsigned int Dimension, unsigned int DegFreedom,const Eigen::MatrixXd& ScalMatr);
79  ~tCopula(){delete BaseDist;}
81 
98  bool SetScaleMatrix(const Eigen::MatrixXd& ScalMatr);
100 
120  bool SetScaleMatrix(const std::vector<double>& mVect, bool RowWise=true);
122 
127  const Eigen::MatrixXd& GetScaleMatrix() const {return LocalVersion->GetScaleMatrix();}
129 
138  bool SetDegreesOfFreedom(unsigned int a);
140 
144  unsigned int GetDegreesOfFreedom() const {return LocalVersion->GetDegreesOfFreedom();}
146 
153  Eigen::MatrixXd ExtractSamples(unsigned int NumSamples)const{if(GetDimension()>1U) return LocalVersion->ExtractSamplesCDF(NumSamples); return Eigen::MatrixXd();}
155 
164  double GetDensity(const Eigen::VectorXd& Coordinates)const;
166 
175  double GetCumulativeDesity(const Eigen::VectorXd& Coordinates)const;
177 
188  Eigen::VectorXd GetQuantile(double Prob)const;
191  };
192 }
193 #endif // tCopula_h__
const Eigen::MatrixXd & GetScaleMatrix() const
Get the scale matrix of the distribution.
Definition: tDist.h:176
bool SetScaleMatrix(const Eigen::MatrixXd &ScalMatr)
Set the scale matrix of the distribution.
Definition: tCopula.cpp:14
virtual double GetDensity(const Eigen::VectorXd &Coordinates) const =0
Computes the probability density function of the copula in correspondence of the supplied coordinates...
unsigned int GetDegreesOfFreedom() const
Get the degrees of freedom of the distribution.
Definition: tDist.h:182
const Eigen::MatrixXd & GetScaleMatrix() const
Get the standardized scale matrix of the distribution.
Definition: tCopula.h:127
Eigen::MatrixXd ExtractSamplesCDF(unsigned int NumSamples) const
Extracts samples from the distribution and returns their marginal CDF.
Definition: tDist.cpp:136
bool SetDegreesOfFreedom(unsigned int a)
Set the degrees of freedom of the distribution.
Eigen::VectorXd GetQuantile(double Prob) const
Computes the inverse copula function in correspondence of the supplied probability.
Definition: tCopula.cpp:52
Copulas base class.
Definition: AbsaractCopula.h:24
double GetDensity(const Eigen::VectorXd &Coordinates) const
Computes the copula density function in correspondence of the supplied coordinates.
Definition: tCopula.cpp:28
unsigned int GetDegreesOfFreedom() const
Get the degrees of freedom of the distribution.
Definition: tCopula.h:144
virtual double GetCumulativeDesity(const Eigen::VectorXd &Coordinates) const =0
Computes the copula function in correspondence of the supplied coordinates.
Eigen::MatrixXd ExtractSamples(unsigned int NumSamples) const
Generates multiple simulations from the copula.
Definition: tCopula.h:153
double GetCumulativeDesity(const Eigen::VectorXd &Coordinates) const
Computes the copula function in correspondence of the supplied coordinates.
Definition: tCopula.cpp:40
tCopula(unsigned int Dimension=2U, unsigned int DegFreedom=1U)
Constructs a standard t copula.
Definition: tCopula.h:58
unsigned int GetDimension() const
Get the dimensionality of the copula.
Definition: AbsaractCopula.h:56
Multivariate Student&#39;s t Distribution
Definition: tDist.h:41
Student&#39;s t Copula Distribution.
Definition: tCopula.h:45