#' Print out the estimated coeffiencts
#'
#' @description Estimated coeffiencts from an x of class "ridgereg".
#' @param x An object of Class "ridgereg", generated by a call to \code{\link{ridgereg}}.
#' @param ... additional arguments.
#' @return A list of estimated coeffiencts.
#' @examples
#' ridgereg_obj <- ridgereg(Petal.Length~Species, datasets::iris)
#' print(ridgereg_obj)
#' @export
print.ridgereg <- function(x,...) {
colnames(x$coef) <- ""
cat("Call:", sep="\n")
cat("ridgereg(formula = ", x$y_name, " ", "~", " ", x$x_names, ", ","data = ", x$data_name, ")", sep = "")
cat(" ", sep = "\n")
cat("Coefficients:", sep="\n")
print(as.matrix(t(x$coef)))
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.