search for: reml_sigma_squar

Displaying 1 result from an estimated 1 matches for "reml_sigma_squar".

Did you mean: reml_sigma_squared
2013 Apr 20
0
Calculate confidence intervals in mgcv for unconditional on the, smoothing parameters
...de(it`s a bit lengthy and has to be tidied up but I wanted to to some manual calculations on the objects afterwards) ### # Simulate 100000 coefficient vectors from the posterior for ß and calculate the critical value ### cov_beta_diff <- vcov(gam_fit) basis_matrix <- model.matrix(gam_fit) reml_sigma_squared <- gam.vcomp(gam_fit) sigma_2_epsilon <- reml_sigma_squared[2,1]^2 smooth_matrix <- basis_matrix%*%vcov(gam_fit,dispersion=1)%*%t(basis_matrix) stdv_f_x <- sqrt(diag(sigma_2_epsilon * smooth_matrix)) set.seed(123) R_sim <- 100000 mean_val <- rep(0, nrow(cov_beta_diff)) coef_di...