Editing a Fortran R Link

I would like to be able to edit the Fortran code mentioned in the fGarch package.

In particular, I would like to edit the available conditional distributions that fGarch :: garchFit can use, i.e. including stable distribution and generalized hyperbolic distribution.

So, looking at the garchFit () function, I delved into (deep) the code, and .aparchLLH.internal () refers to the garchFit () function, and there is a line that refers to the Fortran written code.

The specific line I'm talking about is the following bit of code:

    fit <- .Fortran("garchllh", N = as.integer(N), Y = as.double(.series$x), 
        Z = as.double(.series$z), H = as.double(.series$h), 
        NF = as.integer(NF), X = as.double(params), DPARM = as.double(DPARM), 
        MDIST = as.integer(MDIST), MYPAR = as.integer(MYPAR), 
        F = as.double(0), PACKAGE = "fGarch")

I believe the Fortran garchllh function is what I would like to edit, but I don’t know how to do it so that I can inject new distributions into the garchFit () function.

NB Like the note, I don’t have much experience in Fortran code, but I would like to look at it to see if it can be edited and modified to fit my purpose, so any help in editing the code section in Fortran is much appreciated .. .

+3
source share
1 answer

, - install.packages("fGarch",type="source") , . - , dist.f , , , MDIST, - grep MDIST *.R R . , , - , :)

+2

All Articles