Class MultivariateMoments

java.lang.Object
org.drip.measure.statistics.MultivariateMoments

public class MultivariateMoments
extends java.lang.Object
MultivariateMoments generates and holds the Specified Multivariate Series Mean, Co-variance, and other selected Moments. It provides the following Functionality:
  • Generate the MultivariateMoments Instance from the Series Realizations provided
  • Generate the MultivariateMoments Instance from the Specified Mean and Co-variance Inputs
  • Retrieve the Number of Variates in the Distribution
  • Retrieve the Variates for which the Metrics are available
  • Add the Mean for the Named Variate
  • Retrieve the Mean of the Named Variate
  • Add the Co-variance for the Named Variate Pair
  • Retrieve the Variance of the Named Variate
  • Retrieve the Co-variance of the Named Variate Pair
  • Retrieve the Correlation between the Named Variate Pair

Module Computational Core Module
Library Numerical Analysis Library
Project Rd Continuous/Discrete Probability Measures
Package R1 Rd Thin Thick Moments

Author:
Lakshmi Krishnamurthy
  • Method Summary

    Modifier and Type Method Description
    boolean addCovariance​(java.lang.String variate1Name, java.lang.String variate2Name, double covariance)
    Add the Co-variance for the Named Variate Pair
    boolean addMean​(java.lang.String variateName, double mean)
    Add the Mean for the Named Variate
    double correlation​(java.lang.String variate1Name, java.lang.String variate2Name)
    Retrieve the Correlation between the Named Variate Pair
    double covariance​(java.lang.String variate1Name, java.lang.String variate2Name)
    Retrieve the Co-variance of the Named Variate Pair
    double mean​(java.lang.String variateName)
    Retrieve the Mean of the Named Variate
    int numVariate()
    Retrieve the Number of Variates in the Distribution
    static MultivariateMoments Standard​(java.lang.String[] variateNameArray, double[][] multiVariateArray)
    Generate the MultivariateMoments Instance from the Series Realizations provided
    static MultivariateMoments Standard​(java.lang.String[] variateNameArray, double[] meanArray, double[][] covarianceMatrix)
    Generate the MultivariateMoments Instance from the Specified Mean and Co-variance Inputs
    double variance​(java.lang.String variateName)
    Retrieve the Variance of the Named Variate
    java.util.Set<java.lang.String> variateList()
    Retrieve the Variates for which the Metrics are available

    Methods inherited from class java.lang.Object

    equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Method Details

    • Standard

      public static final MultivariateMoments Standard​(java.lang.String[] variateNameArray, double[][] multiVariateArray)
      Generate the MultivariateMoments Instance from the Series Realizations provided
      Parameters:
      variateNameArray - Array of Variate Name Headers
      multiVariateArray - Array of Variate Realization Arrays
      Returns:
      The MultivariateMoments Instance
    • Standard

      public static final MultivariateMoments Standard​(java.lang.String[] variateNameArray, double[] meanArray, double[][] covarianceMatrix)
      Generate the MultivariateMoments Instance from the Specified Mean and Co-variance Inputs
      Parameters:
      variateNameArray - Array of Variate Name Headers
      meanArray - Array of Variate Means
      covarianceMatrix - Double Array of the Variate Co-variance
      Returns:
      The MultivariateMoments Instance
    • numVariate

      public int numVariate()
      Retrieve the Number of Variates in the Distribution
      Returns:
      The Number of Variates in the Distribution
    • variateList

      public java.util.Set<java.lang.String> variateList()
      Retrieve the Variates for which the Metrics are available
      Returns:
      The Set of Variates
    • addMean

      public boolean addMean​(java.lang.String variateName, double mean)
      Add the Mean for the Named Variate
      Parameters:
      variateName - The Named Variate
      mean - The Variate Mean
      Returns:
      TRUE - The Variate Mean successfully added
    • mean

      public double mean​(java.lang.String variateName) throws java.lang.Exception
      Retrieve the Mean of the Named Variate
      Parameters:
      variateName - The Named Variate
      Returns:
      Mean of the Named Variate
      Throws:
      java.lang.Exception - Thrown if the Named Variate Mean cannot be retrieved
    • addCovariance

      public boolean addCovariance​(java.lang.String variate1Name, java.lang.String variate2Name, double covariance)
      Add the Co-variance for the Named Variate Pair
      Parameters:
      variate1Name - The Named Variate #1
      variate2Name - The Named Variate #2
      covariance - The Variate-Pair Covariance
      Returns:
      TRUE - The Variate Pair Co-variance successfully added
    • variance

      public double variance​(java.lang.String variateName) throws java.lang.Exception
      Retrieve the Variance of the Named Variate
      Parameters:
      variateName - The Named Variate
      Returns:
      Variance of the Named Variate
      Throws:
      java.lang.Exception - Thrown if the Named Variate Variance cannot be retrieved
    • covariance

      public double covariance​(java.lang.String variate1Name, java.lang.String variate2Name) throws java.lang.Exception
      Retrieve the Co-variance of the Named Variate Pair
      Parameters:
      variate1Name - The Named Variate #1
      variate2Name - The Named Variate #2
      Returns:
      Co-variance of the Named Variate Pair
      Throws:
      java.lang.Exception - Thrown if the Named Variate Co-variance cannot be retrieved
    • correlation

      public double correlation​(java.lang.String variate1Name, java.lang.String variate2Name) throws java.lang.Exception
      Retrieve the Correlation between the Named Variate Pair
      Parameters:
      variate1Name - The Named Variate #1
      variate2Name - The Named Variate #2
      Returns:
      Correlation between the Named Variate Pair
      Throws:
      java.lang.Exception - Thrown if the Named Variate Correlation cannot be retrieved