Package: sgdGMF 1.0

Cristian Castiglione

sgdGMF: Estimation of Generalized Matrix Factorization Models via Stochastic Gradient Descent

Efficient framework to estimate high-dimensional generalized matrix factorization models using penalized maximum likelihood under a dispersion exponential family specification. Either deterministic and stochastic methods are implemented for the numerical maximization. In particular, the package implements the stochastic gradient descent algorithm with a block-wise mini-batch strategy to speed up the computations and an efficient adaptive learning rate schedule to stabilize the convergence. All the theoretical details can be found in Castiglione et al. (2024, <doi:10.48550/arXiv.2412.20509>). Other methods considered for the optimization are the alternated iterative re-weighted least squares and the quasi-Newton method with diagonal approximation of the Fisher information matrix discussed in Kidzinski et al. (2022, <http://jmlr.org/papers/v23/20-1104.html>).

Authors:Cristian Castiglione [aut, cre], Davide Risso [ctb], Alexandre Segers [ctb]

sgdGMF_1.0.tar.gz
sgdGMF_1.0.tar.gz(r-4.5-noble)sgdGMF_1.0.tar.gz(r-4.4-noble)
sgdGMF_1.0.tgz(r-4.4-emscripten)sgdGMF_1.0.tgz(r-4.3-emscripten)
sgdGMF.pdf |sgdGMF.html
sgdGMF/json (API)

# Install 'sgdGMF' in R:
install.packages('sgdGMF', repos = c('https://cran.r-universe.dev', 'https://cloud.r-project.org'))

Bug tracker:https://github.com/cristiancastiglione/sgdgmf/issues

Uses libs:
  • openblas– Optimized BLAS
  • c++– GNU Standard C++ Library v3
  • openmp– GCC OpenMP (GOMP) support library

openblascppopenmp

4.34 score 109 scripts 14 exports 80 dependencies

Last updated 7 days agofrom:1d10f9e19e. Checks:2 OK. Indexed: no.

TargetResultLatest binary
Doc / VignettesOKFeb 13 2025
R-4.5-linux-x86_64OKFeb 13 2025

Exports:refitset.control.airwlsset.control.algset.control.block.sgdset.control.coord.sgdset.control.cvset.control.initset.control.newtonsgdgmf.cvsgdgmf.fitsgdgmf.initsgdgmf.ranksim.gmf.datasimulate

Dependencies:abindbackportsbootbroomcarcarDataclicodetoolscolorspacecorrplotcowplotcpp11DerivdoBydoParalleldplyrfansifarverforeachFormulagenericsggplot2ggpubrggrepelggsciggsignifgluegridExtragtableisobanditeratorslabelinglatticelifecyclelme4magrittrMASSMatrixMatrixModelsmgcvmicrobenchmarkminqamodelrmunsellnlmenloptrnnetnumDerivpbkrtestpillarpkgconfigplyrpolynompurrrquantregR6rbibutilsRColorBrewerRcppRcppArmadilloRcppEigenRdpackreformulasreshape2rlangRSpectrarstatixscalesSparseMstringistringrSuppDistssurvivaltibbletidyrtidyselectutf8vctrsviridisLitewithr

Algorithm comparison

Rendered fromalgorithms.Rmdusingknitr::rmarkdownon Feb 13 2025.

Last update: 2025-02-13
Started: 2025-02-13

Initialization algorithms

Rendered frominitialization.Rmdusingknitr::rmarkdownon Feb 13 2025.

Last update: 2025-02-13
Started: 2025-02-13

Introduction to the sgdGMF package

Rendered fromintroduction.Rmdusingknitr::rmarkdownon Feb 13 2025.

Last update: 2025-02-13
Started: 2025-02-13

Analysis of the residuals

Rendered fromresiduals.Rmdusingknitr::rmarkdownon Feb 13 2025.

Last update: 2025-02-13
Started: 2025-02-13

Readme and manuals

Help Manual

Help pageTopics
Biplot of an initialized GMF modelbiplot.initgmf
Biplot of a GMF modelbiplot.sgdgmf
Extract the coefficient of an initialized GMF modelcoef.initgmf coefficients.initgmf
Extract the coefficient of a GMF modelcoef.sgdgmf coefficients.sgdgmf
Compute deviance, AIC and BIC of an initialized GMF modelAIC.initgmf BIC.initgmf deviance.initgmf
Compute deviance, AIC and BIC of a GMF modelAIC.sgdgmf BIC.sgdgmf deviance.sgdgmf
Extract the fitted values of an initialized GMF modelfitted.initgmf
Extract the fitted values of a GMF modelsfitted.sgdgmf
Heatmap of an initialized GMF modelimage.initgmf
Heatmap of a GMF modelimage.sgdgmf
Plot diagnostics for an initialized GMF modelplot.initgmf
Plot diagnostics for a GMF modelplot.sgdgmf
Predict method for GMF modelspredict.sgdgmf
Print the fundamental characteristics of an initialized GMFprint.initgmf
Print the fundamental characteristics of a GMFprint.sgdgmf
Refine the final estimate of a GMF modelrefit.sgdgmf
Extract the residuals of an initialized GMF modelresid.initgmf residuals.initgmf
Extract the residuals of a GMF modelresid.sgdgmf residuals.sgdgmf
Screeplot for the residuals of an initialized GMF modelscreeplot.initgmf
Screeplot for the residuals of a GMF modelscreeplot.sgdgmf
Check and set the control parameters for the AIRWLS algorithmset.control.airwls
Check and set the control parameters for the select optimization algorithmset.control.alg
Check and set the control parameters for the blockwise-SGD algorithmset.control.block.sgd
Check and set the control parameters for the coordinate-SGD algorithmset.control.coord.sgd
Check and set the cross-validation parametersset.control.cv
Check and set the initialization parameters for a GMF modelset.control.init
Check and set the control parameters for the Newton algorithmset.control.newton
Model selection via cross-validation for generalized matrix factorization modelssgdgmf.cv
Factorize a matrix of non-Gaussian observations using GMFsgdgmf.fit
Rank selection via eigenvalue-gap methodssgdgmf.rank
Simulate non-Gaussian data from a GMF modelsim.gmf.data
Simulate new datasimulate
Simulate method for GMF modelssimulate.sgdgmf