Library: | VaR |
See also: | VaRcharfDG |
Quantlet: | VaRcgfDG | |
Description: | computes the cumulant generating function (cgf) for the class of quadratic forms of Gaussian vectors. |
Usage: | s = VaRcgfDG(t,par) | |
Input: | ||
t | the complex argument to the cgf | |
par | a list defining the distribution; contains at least the following components: theta - the constant term delta - the linear term lambda - the diagonal of the quadratic term | |
Output: | ||
s | the value of the cgf at t |
library("plot") library("VaR") library("math") proc() = VaRcgfDGtest(par,n,xlim) dt =(xlim[2]-xlim[1])/(n-1) t = xlim[1] +(0:(n-1))*dt r = VaRcgfDG(complex(t,t*0),par) z1 = setmask(t~r.re, "line", "blue") plot(z1) endp theta = 0 delta = #(1) lambda= #(0.1) par = list(theta,delta,lambda) VaRcgfDGtest(par,100,#(-2,2))
Plots the cumulant generating function for a distribution, which is close to normal distribution. The graph is close to a parabola.