# Generated by using Rcpp::compileAttributes() -> do not edit by hand
# Generator token: 10BE3573-1514-4C36-9D1C-5A225CD40393
#' Get an initial set of putative variables for the GAM algorithm
#'
#' @param Z matrix of putative variables
#' @param Yr the (possibly transformed) response
#' @param mincor a threshold of (absolute) correlation above which a pair is considered highly correlated
#' @return a list containing variables to ignore because they are highly correlated with other, and SLR coefficients
initVals <- function(Z, Yr, mincor = 0.7) {
.Call('_SEMMS_initVals', PACKAGE = 'SEMMS', Z, Yr, mincor)
}
#' Get an initial set of putative variables for the GAM algorithm
#'
#' @param initidx an initial set of variables to use in the fitting algorithm
#' @param initval the values (-1 or 1) of the initial set of preditors
#' @param Yr the response vector
#' @param Xr the fixed-effect design matrix
#' @param Z the matrix of all putative variables
#' @param distr the GLM distribution to fit (N=Normal, B=binary, P=Poisson)
#' @param randomize Boolean - whether to run the greedy or randomized version
#' @param mincor a threshold of (absolute) correlation above which a pair is considered highly correlated
#' @param maxsteps maximum number of GAM iterations
#' @param minchange the minimum difference in log-likelihood between consecutive iterations below which we assume that the algorithm has converged
#' @param ptf Boolean - whether to print debug messages to SEMMS.log
#' @return a list containing the index of non-null variables (columns in Z), the mixture model parameters, the sign of the selected coefficients, a matrix with posterior probabilities, and an indicator array for locked out variables
GAMupdate <- function(initidx, initval, Yr, Xr, Z, distr = 'N', randomize = TRUE, mincor = 0.7, maxsteps = 20L, minchange = 1, ptf = TRUE) {
.Call('_SEMMS_GAMupdate', PACKAGE = 'SEMMS', initidx, initval, Yr, Xr, Z, distr, randomize, mincor, maxsteps, minchange, ptf)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.