Last data update: 2014.03.03

R: The Multivariate t-Distribution
ddmvtR Documentation

The Multivariate t-Distribution

Description

Density and random generation for Multivariate t-distributions with mean vector mean, covariance matrix cov, and degrees of freedom nu.

Usage

ddmvt(dat,n, p, mean, cov, nu)
rdmvt(    n, p, mean, cov, nu)

Arguments

dat

An n by p numeric matrix, the dataset

n

An integer, the number of observations

p

An integer, the dimension of data

mean

A length of p vector, the mean

cov

A p by p matrix, the covariance

nu

A positive number, the degrees of freedom

Value

ddmvt gives the density values; rdmvt generates the random numbers

See Also

rdemmix,ddmvn,ddmsn, ddmst,rdmvn,rdmsn, rdmst.

Examples

n <- 100
p <- 2

mean   <- rep(0,p)
cov    <- diag(p)
nu     <-  3

set.seed(3214)

x   <- rdmvt(    n,p,mean,cov,nu)

den <- ddmvt(x  ,n,p,mean,cov,nu)

Results


R version 3.3.1 (2016-06-21) -- "Bug in Your Hair"
Copyright (C) 2016 The R Foundation for Statistical Computing
Platform: x86_64-pc-linux-gnu (64-bit)

R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.

R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.

Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.

> library(EMMIXskew)
Loading required package: lattice
Loading required package: mvtnorm
Loading required package: KernSmooth
KernSmooth 2.23 loaded
Copyright M. P. Wand 1997-2009
> png(filename="/home/ddbj/snapshot/RGM3/R_CC/result/EMMIXskew/ddmvt.Rd_%03d_medium.png", width=480, height=480)
> ### Name: ddmvt
> ### Title: The Multivariate t-Distribution
> ### Aliases: ddmvt rdmvt
> ### Keywords: cluster datasets
> 
> ### ** Examples
> 
> n <- 100
> p <- 2
> 
> mean   <- rep(0,p)
> cov    <- diag(p)
> nu     <-  3
> 
> set.seed(3214)
> 
> x   <- rdmvt(    n,p,mean,cov,nu)
> 
> den <- ddmvt(x  ,n,p,mean,cov,nu)
> 
> 
> 
> 
> 
> 
> dev.off()
null device 
          1 
>