Sparse and Dense Matrix Classes and Methods

A rich hierarchy of matrix classes, including triangular, symmetric, and diagonal matrices, both dense and sparse and with pattern, logical and numeric entries. Numerous methods for and operations on these matrices, using 'LAPACK' and 'SuiteSparse' libraries.


News

Reference manual

It appears you don't have a PDF plugin for this browser. You can click here to download the reference manual.

install.packages("Matrix")

1.3-4 by Martin Maechler, 5 months ago


http://Matrix.R-forge.R-project.org/


Report a bug at https://r-forge.r-project.org/tracker/?group_id=61


Browse source code at https://github.com/cran/Matrix


Authors: Douglas Bates [aut] , Martin Maechler [aut, cre] , Timothy A. Davis [ctb] (SuiteSparse and 'cs' C libraries , notably CHOLMOD , AMD; collaborators listed in dir(pattern = '^[A-Z]+[.]txt$' , full.names=TRUE , system.file('doc' , 'SuiteSparse' , package='Matrix'))) , Jens Oehlschlägel [ctb] (initial nearPD()) , Jason Riedy [ctb] (condest() and onenormest() for octave , Copyright: Regents of the University of California) , R Core Team [ctb] (base R matrix implementation)


Documentation:   PDF Manual  


Task views: Econometrics, Multivariate Statistics, Numerical Mathematics


GPL (>= 2) | file LICENCE license


Imports methods, graphics, grid, stats, utils, lattice

Suggests expm, MASS

Enhances MatrixModels, graph, SparseM, sfsmisc, igraph, maptools, sp, spdep


Imported by ADMM, AGHmatrix, AGPRIS, AHM, AICcmodavg, AROC, ARpLMEC, AdaptiveSparsity, ArCo, BBSSL, BCA1SG, BFpack, BGVAR, BGmisc, BLPestimatoR, BOSO, BOSSreg, BTYD, BayesLN, BayesMRA, BayesMassBal, BayesNSGP, BayesS5, BayesSUR, BayesSampling, BayesianTools, BeSS, Bergm, BeviMed, BigQuic, BinOrdNonNor, BlockCov, CARlasso, CDSeq, CDatanet, CEGO, CIAAWconsensus, CISE, CLVTools, CMShiny, CNVScope, CNull, CRF, CVXR, CatEncoders, CausalMBSTS, ChainLadder, ClimMobTools, CliquePercolation, ClustAssess, CoSMoS, CollocInfer, CompareCausalNetworks, Corbi, Countr, CovCombR, CovTools, Crossover, Cyclops, DAISIE, DAMOCLES, DCD, DCLEAR, DDD, DHARMa, DNMF, DOBAD, DRaWR, DUBStepR, DWLasso, DiffNet, Dire, DrBats, EFDR, EGAnet, EdSurvey, EmbedSOM, Epi, FDboost, FEprovideR, FRK, FSInteract, FeatureHashing, FindIt, FlexGAM, ForecastComb, FuncNN, GENLIB, GENMETA, GFD, GFisher, GGMnonreg, GHap, GLMpack, GMMAT, GPvecchia, GUniFrac, GWSDAT, GeomComb, GillespieSSA2, HCD, HDCI, HDPenReg, HLMdiag, HeteroGGM, Hmsc, HyperG, ICBioMark, IDE, IFAA, IMAGE, INLABMA, IPCAPS, ITRSelect, IsingFit, L0Learn, LANDD, LICORS, LKT, LMERConvenienceFunctions, LMMstar, LRQMM, LSX, LassoBacktracking, MAGEE, MANOVA.RM, MCMCprecision, MEGENA, MESS, MFPCA, MGDrivE2, MIIVsem, MLGL, MM4LMM, MMeM, MRFcov, MRTSampleSizeBinary, MTAR, MachineShop, MatrixModels, MendelianRandomization, MiRKAT, MixedPsy, MixfMRI, MoMPCA, MoTBFs, ModelMatrixModel, MonteCarloSEM, Morpho, MuChPoint, MuMIn, MultiVarMI, NPMLEmix, NVCSSL, NetMix, NetworkComparisonTest, NetworkDistance, NetworkReg, NonProbEst, NormalBetaPrime, OpenMx, OptimalDesign, PBImisc, PCADSC, PEIP, PLNmodels, PLmixed, PQLseq, PRIMAL, PROreg, PUlasso, PanCanVarSel, PanelMatch, PartCensReg, PenCoxFrail, PenIC, PerFit, PlackettLuce, Platypus, ProcMod, Qtools, R2MLwiN, RAINBOWR, REndo, RGF, RHPCBenchmark, RKEEL, RMLPCA, RMThreshold, RNGforGPD, ROCnReg, ROI.plugin.clp, ROI.plugin.ecos, ROI.plugin.osqp, RPANDA, RRPP, RSC, RSSL, RSiena, RSpectra, RVFam, RaceID, RcppEigen, RcppML, Rdtq, ResourceSelection, RevEcoR, Riemann, Rlinsolve, Rnmr1D, RobKF, Rphylopars, Rsurrogate, SAR, SAVER, SCGLR, SCORNET, SCORPIUS, SDALGCP, SEMgraph, SID, SIHR, SIRE, SISIR, SLBDD, SLOPE, SLTCA, SMNCensReg, SPAS, SSN, STB, SUMMER, ScreenClean, Seurat, SeuratObject, SightabilityModel, Signac, SignacX, SimCorrMix, SimInf, SimMultiCorrData, SmCCNet, SoupX, SpiceFP, SplitKnockoff, SteppedPower, SwarmSVM, SystemicR, TAG, TANDEM, TCA, TFisher, TMB, TOHM, TRMF, TSsmoothing, TTCA, TULIP, TextForecast, TooManyCellsR, TopicScore, TraceAssist, VCA, ViSiElse, WLasso, WeMix, WoodburyMatrix, ZIPFA, abess, abnormality, abtest, adjclust, ahMLE, alakazam, albatross, altmeta, animalEKF, anndata, anticlust, apcluster, apdesign, applicable, ar.matrix, arc, argo, aricode, ashr, asnipe, autoMFA, automultinomial, backbone, bamlss, basefun, bastah, bbmle, beam, benchmarkme, bestridge, biClassify, bibliometrix, bigsnpr, biospear, blapsr, blatent, blavaan, blin, blockForest, blockmodeling, bootnet, brainGraph, brant, bravo, brglm2, bridgesampling, brms, btergm, cSEM, cape, castor, cat.dt, catch, cate, cepreader, chinese.misc, chords, cleanNLP, clevr, clustvarsel, cmR, cmaRs, cna, coalescentMCMC, coca, codingMatrices, colourvision, comato, complexplus, conText, conleyreg, conquer, control, cope, copula, corTest, corncob, corpustools, cotram, covsim, coxinterval, coxme, crisp, crqa, ctrialsgov, ctsem, ctsemOMX, cvCovEst, cytominer, dbcsp, ddpca, deepNN, deepregression, demu, denoiseR, denseFLMM, detect, did, did2s, didimputation, diffusionMap, digitalDLSorteR, diproperm, dipw, disaggregation, discfrail, diversityForest, dmt, dnet, doBy, dplR, dr4pl, drf, dtwclust, dyngen, dynr, dynutils, dynwrap, eBsc, eCAR, eRm, easySdcTable, eatATA, econet, economiccomplexity, ecpc, edmcr, ef, effectFusion, enerscape, epca, epidemia, ergMargins, ergm, eva, evclust, evolqg, expose, ez, fExpressCertificates, fGarch, face, facilitation, fad, fastLink, fastNaiveBayes, fastcox, fbar, fcaR, fdaMocca, fdapace, fdasrvf, fglsnet, fiberLD, file2meco, flars, flexsurv, fmcmc, frailtyEM, frechet, fssemR, fundiversity, fuser, fwildclusterboot, gMCP, gMOIP, gRbase, gWQS, gamm4.test, gasper, gcbd, geecure, geex, gemma2, geonet, gesso, gfilmm, ggmix, gif, gllvm, glmmLasso, glmmTMB, glmmsr, glmnetUtils, gnm, goric, gpboost, gplite, graph4lg, graphicalVAR, graphsim, greed, grf, grpreg, gsbm, gustave, gwer, hIRT, hal9001, harmony, hbm, hbsae, hergm, hero, hhcartr, hierarchicalDS, hierarchicalSets, highriskzone, higrad, hmgm, hmi, hmlasso, hopit, hrqglas, hscovar, hts, huge, iAdapt, iCARH, iCellR, iGraphMatch, iRF, iTOP, ib, icdGLM, igraph, iilasso, immcp, influence.ME, influenceR, inlabru, irtplay, isodistrreg, isokernel, ivmodel, jlsm, joineRML, joineRmeta, keyATM, kknn, klic, knn.covertree, knockoff, koRpus, ks, l1spectral, landsepi, latentcor, lavaSearch2, leastcostpath, leiden, lgcp, lime, lineartestr, lmds, lmeresampler, lmvar, locStra, logbin, lognorm, lolog, lpbrim, lsbs, ltmle, ludic, lvnet, madness, madrat, makemyprior, maotai, marcher, marked, markovchain, mboost, mbr, mbsts, mcglm, mcmcsae, mcompanion, mdatools, mdw, medflex, merDeriv, metaBLUE, metaMix, metaSDTreg, metaSEM, metafuse, metagear, mfaces, mgcv, mgss, miRNAss, micemd, midasr, mirt, misclassGLM, missCompare, missSBM, mistral, mixKernel, mixedCCA, mlapi, mlergm, mlfit, mlmi, mlmm.gwas, mlt, mltools, mme, mmmgee, modnets, mosaic, motifcluster, moult, msaeRB, msaenet, mstDIF, multiAssetOptions, multibiplotGUI, multicross, multimark, multinma, multiviewtest, mumm, mvSLOUCH, mvord, mvrsquared, natural, net4pg, netCoin, netchain, netcom, netcontrol, netdiffuseR, netgsa, netgwas, netrankr, netregR, networkR, networktree, neuroim, newsmap, nlmixr, nlmm, nlraa, nmathresh, nmslibR, nonlinearTseries, nopaco, nowcasting, nprcgenekeepr, nutriNetwork, nvmix, oem, ompr, ompr.roi, ondisc, oppr, optBiomarker, optiSel, optiSolve, optweight, opusminer, ordinal, osqp, palasso, panelvar, parglm, pbkrtest, pcgen, pcts, pdynmc, pedigreeTools, pencal, perARMA, permubiome, permuco, pez, phangorn, phia, phyloregion, phyr, pkggraph, pmpp, poismf, polmineR, polyMatrix, polycor, polywog, poolfstat, powerplus, pre, predictmeans, primePCA, profoc, provGraphR, proxyC, prozor, psychonetrics, ptf, pulsar, pvclass, qape, qgraph, qrjoint, quantable, quanteda, quanteda.textmodels, quanteda.textplots, quanteda.textstats, quantkriging, quantreg, r2glmm, rNeighborGWAS, rNeighborQTL, rPanglaoDB, rWind, rWishart, ragt2ridges, randomLCA, ranger, raptr, rare, rbenvo, rbi.helpers, rbridge, rcage, readsparse, recipes, recometrics, refund, regmedint, repolr, rescue, reticulate, riskParityPortfolio, riskclustr, rmatio, rmgarch, robustreg, robustsur, rodd, rpql, rr2, rsetse, rsmatrix, rsparse, rsq, rstanarm, rsvd, sNPLS, saeRobust, samc, sanic, sarsop, sasfunclust, sbfc, scDHA, scPOP, scRNAstat, scTenifoldKnk, scTenifoldNet, scUtils, scalpel, scam, sccore, sctransform, sdpdth, seededlda, selfmade, semnova, seqHMM, seqR, shapr, sharpr2, signnet, simExam, simglm, singleCellHaystack, sirus, sklarsomega, slanter, slimrec, smam, smoothedLasso, smurf, soc.ca, spANOVA, spBayes, spGARCH, spaMM, sparseFLMM, sparseHessianFD, sparseMVN, sparsebnUtils, sparseinv, sparsesvd, sparsevar, sparsio, spatgraphs, spatstat.Knet, spatstat.core, spatstat.data, spatstat.linnet, spatsurv, spdep, spectralGraphTopology, spflow, sphet, splm, spmoran, spreadr, spsur, sqp, squeezy, stR, stabm, starm, starnet, statcomp, stfit, stm, stocc, strand, stylest, sumFREGAT, superbiclust, surbayes, surrosurv, surveillance, survival, survivalsvm, survtmle, susieR, svs, symphony, synlik, syt, tcl, tea, tensorTS, tensorr, text2map, text2vec, textplot, textrecipes, themetagenomics, threeboost, tidyMicro, tidylda, tidytext, tmle.npvi, tram, tramME, treeDA, trustOptim, tsDyn, tscopula, tsrobprep, ttTensor, tukeytrend, tvR, ubms, udpipe, ui, umx, ungroup, unmarked, useful, varTestnlme, varbvs, varjmcm, vennLasso, visa, votesys, wactor, waydown, wfe, widyr, xLLiM, xgboost, xrf, xtreg2way.

Depended on by ADDT, ADMMnet, APML0, BCE, BSW, BTLLasso, BacArena, BayesFactor, BinNonNor, BinNor, Boptbd, BullsEyeR, CLSOCP, CRTgeeDR, CVST, CodataGS, DRR, DTRlearn2, DWDLargeR, DoubleCone, EMCluster, EMMREML, FSTpackage, FoReco, GPvam, GaussSuppression, GeDS, GenOrd, GenoScan, GeoDE, GlarmaVarSel, GrassmannOptim, HSDiC, HelpersMG, HiCfeat, IGG, KnockoffScreen, L1mstate, LPmerge, LSC, MAP, MBC, MBSP, MCMCglmm, MDPtoolbox, MargCond, Matrix.utils, MatrixExtra, MedSurvey, Metatron, MultiGHQuad, MultiOrd, MultiVarSel, N2R, NegBinBetaBinreg, NetworkRiskMeasures, ORDER2PARENT, OrdNor, PCovR, PERMANOVA, POINT, PRISMA, PhylogeneticEM, PivotalR, PoisBinNonNor, PoisBinOrd, PoisBinOrdNonNor, PoisBinOrdNor, PoisNonNor, PoisNor, PrevMap, ProbitSpatial, QPmin, QRM, QZ, RCBR, REBayes, REREFACT, RFGLS, RGENERATEPREC, RNewsflow, RSarules, RealVAMS, Rediscover, RegSDC, Rmagic, SALES, SC.MEB, SEAGLE, SKAT, SOR, SSBtools, SmallCountRounding, StableEstim, StratifiedSampling, SuperPCA, TPEA, TimeProjection, TreePar, TropFishR, VAM, WGScan, WaveSampling, adapt4pv, adaptMCMC, adaptsmoFMRI, addhaz, ahaz, arm, arules, arulesCBA, aster2, bc3net, bgsmtr, biglasso, birankr, cAIC4, centiserve, cgam, cjoint, climwin, conos, covLCA, cplm, crrp, csurvey, cthreshER, ctmcmove, curephEM, dataPreparation, dcGOR, dclone, dglars, dhglm, distrom, dmm, epistasis, epoc, excursions, expectreg, expm, fanc, fastRG, fastclime, fda, fdaPDE, flare, frailtyHL, gamlr, gamlss.lasso, gamm4, gcdnet, gdistance, geeM, genlasso, geomorph, geostatsp, glmm, glmnet, gptk, gremlin, growthrate, grpCox, gvcm.cat, gwerAM, hdlm, hglm, hglm.data, hierSDR, ibmdbR, inca, irlba, islasso, isotonic.pen, kinship2, lassoscore, lcpm, leidenAlg, lfe, lingmatch, lme4, logcondiscr, mapfit, mcen, mclogit, mdhglm, mediation, mefa4, metafor, mgwrsar, mi, midasml, mind, msda, msgl, mvglmmRank, nadiv, optbdmaeAT, optrcdmaeAT, pagoda2, pedgene, pedigree, pedigreemm, penDvine, pense, phateR, picasso, pleio, prodest, qlcMatrix, qpcR, quadrupen, qut, rBMF, rSPDE, ramps, randnet, recommenderlab, reglogit, rliger, robustlmm, rwc, sRDA, sSDR, sbw, scpm, sdpt3r, sdwd, sensory, serrsBayes, sglOptim, sglasso, sharpPen, snpReady, softImpute, sommer, soptdmaeA, sparseLRMatrix, sparsenet, sparsestep, spatialprobit, spatialreg, spatstat.sparse, speedglm, ssfa, stcos, sureLDA, surf, survey, svmplus, svydiags, sybil, sybilccFBA, sybilcycleFreeFlux, systemfit, textTinyR, textir, textmineR, tmvtnorm, triversity, tsapp, tvReg, uwot, vagam, winRatioAnalysis, wordspace.

Suggested by AgreementInterval, CARBayes, CLA, ChoiceModelR, DGCA, DPQ, DPQmpfr, DoE.MIParray, ECOSolveR, EIX, ESEA, FSelectorRcpp, GDINA, HSAUR, HSAUR2, KFAS, LiblineaR, LncPath, MARSS, NCmisc, PAGI, PRIMME, R.matlab, RcppArmadillo, Rmpfr, RxODE, Ryacas, Ryacas0, STPGA, SimSurvNMarker, StanHeaders, WeightSVM, afex, alphastable, bigsparser, brokenstick, broom, broom.mixed, car, caracas, caret, cccd, ccdrAlgorithm, classGraph, clubSandwich, cluster, cmfrec, cobs, corpus, corrgram, cpr, cvwrapr, diffusr, dils, dimRed, discSurv, dyndimred, e1071, ePCR, extraTrees, eyetrackingR, fabletools, flacco, funrar, gap, gcKrig, gear, gemtc, genscore, gets, ggeffects, glmpca, gmodels, h2o, h2o4gpu, hamlet, hardhat, hdi, hmclearn, hydra, insight, ivdesign, ivmte, lava, lda, lfactors, loe, lotri, matrixpls, mefa, mlr3, mlt.docreg, modelbased, naivebayes, neat, parameters, parsnip, pcFactorStan, pcalg, performance, pergola, pmml, porridge, psqn, psr, r2mlm, rARPACK, rattle, recosystem, rmumps, robustbase, rope, round, rstan, sageR, sf, sfsmisc, simstudy, sirt, spam, sptm, srvyr, stabledist, stanette, tableone, tiledb, tramnet, tscount, visreg, xrnet, zenplots.

Enhanced by Rcplex, Rcsdp, Rsymphony, coop, isotree, rviewgraph, skmeans, slam.


See at CRAN