Purpose
The purpose of the script is to use IFM method to cull out the correlation matrix of three assets using t marginals

temp.ret contains the returns of three assets

> head(temp.ret, 2)
GMT
           Nifty100Ret    GoldRet     Liquid
2004-05-28   0.4835926 0.08272835 0.03473777
2004-05-31   0.4595340 0.06904175 0.03464168
> tail(temp.ret, 2)
GMT
           Nifty100Ret   GoldRet     Liquid
2010-05-27   0.2201230 0.2832164 0.02502719
2010-05-28   0.2331315 0.2569849 0.02505284

Use t dist as marginals and estimate the params

> test <- temp.ret[, 1]
> loglik.marg <- function(b, x) {
+     return(sum(dt(x, df = b[1], ncp = b[2], log = T)))
+ }
> b1hat <- optim(c(0.3, 0.1), fn = loglik.marg, x = test, control = list(fnscale = -1))$par
> b1hat
[1] 3.780779e+05 2.647473e-01

Clearly it gives that noncentrality is close to 0.2 and the
dof suggests that it is normal

> test <- temp.ret[, 2]
> loglik.marg <- function(b, x) {
+     return(sum(dt(x, df = b[1], ncp = b[2], log = T)))
+ }
> b1hat <- optim(c(0.3, 0.1), fn = loglik.marg, x = test, control = list(fnscale = -1))$par
> b1hat
[1] 2.336480e+05 1.985186e-01

Clearly it gives that noncentrality is close to 0.2 and the
dof suggests that it is normal

> test <- temp.ret[, 3]
> loglik.marg <- function(b, x) {
+     return(sum(dt(x, df = b[1], ncp = b[2], log = T)))
+ }
> b1hat <- optim(c(0.3, 0.1), fn = loglik.marg, x = test, control = list(fnscale = -1))$par
> b1hat
[1] 8.223708e+06 4.748920e-02

Clearly it gives that noncentrality is close to 0.2 and the
dof suggests that it is normal

The experiment of using t marginals has failed as the mle estimates a high dof .