Package: Rfast 2.1.0

Manos Papadakis

Rfast: A Collection of Efficient and Extremely Fast R Functions

A collection of fast (utility) functions for data analysis. Column and row wise means, medians, variances, minimums, maximums, many t, F and G-square tests, many regressions (normal, logistic, Poisson), are some of the many fast functions. References: a) Tsagris M., Papadakis M. (2018). Taking R to its limits: 70+ tips. PeerJ Preprints 6:e26605v1 <doi:10.7287/peerj.preprints.26605v1>. b) Tsagris M. and Papadakis M. (2018). Forward regression in R: from the extreme slow to the extreme fast. Journal of Data Science, 16(4): 771--780. <doi:10.6339/JDS.201810_16(4).00006>. c) Chatzipantsiou C., Dimitriadis M., Papadakis M. and Tsagris M. (2020). Extremely Efficient Permutation and Bootstrap Hypothesis Tests Using Hypothesis Tests Using R. Journal of Modern Applied Statistical Methods, 18(2), eP2898. <doi:10.48550/arXiv.1806.10947>.

Authors:Manos Papadakis [aut, cre, cph], Michail Tsagris [aut], Marios Dimitriadis [ctb], Stefanos Fafalios [aut], Ioannis Tsamardinos [ctb], Matteo Fasiolo [ctb], Giorgos Borboudakis [ctb], John Burkardt [ctb], Changliang Zou [ctb], Kleanthi Lakiotaki [ctb], Christina Chatzipantsiou [ctb]

Rfast_2.1.0.tar.gz
Rfast_2.1.0.tar.gz(r-4.5-noble)Rfast_2.1.0.tar.gz(r-4.4-noble)
Rfast_2.1.0.tgz(r-4.4-emscripten)Rfast_2.1.0.tgz(r-4.3-emscripten)
Rfast.pdf |Rfast.html
Rfast/json (API)
NEWS

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

Peer review:

Bug tracker:https://github.com/rfastofficial/rfast/issues

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

9.27 score 5 stars 155 packages 1.1k scripts 15k downloads 5 mentions 441 exports 5 dependencies

Last updated 1 years agofrom:9f7ac98582. Checks:OK: 1 NOTE: 1. Indexed: no.

TargetResultDate
Doc / VignettesOKNov 03 2024
R-4.5-linux-x86_64NOTENov 03 2024

Exports:acg.mleAddToNamespaceall_equalsallbetasallttestsancova1ancovasanova_propreganova_qpois.reganova_quasipois.reganova1anovasapply.conditionar1as_integeras.Rfast.functionaucbcbcdcorbeta.mlebetabinom.mlebetageom.mlebetaprime.mlebic.corfsregbic.fs.regbinary_searchbincombbinom.mleblock.anovablock.anovasboot.ttest2borel.mlebs.regbtmprobscat.goftestscauchy.mlecheck_datacheckAliasescheckExamplescheckNamespacecheckTFcheckUsagechi2Testchi2Test_univariatechi2testschisq.mlecholeskyChoosecirclin.corcoeffcol.coxpoisratcol.yulecolAllcolanovascolAnycolar1colaucscolCountValuescolCumMaxscolCumMinscolCumProdscolCumSumscolcvscoldiffscolexp2.mlecolexpmlecolFalsecolgammamlecolgeom.mlecolhameanscolinvgauss.mlecolkurtosiscollaplace.mlecollindley.mlecolMadscolmaxboltz.mlecolMaxscolmeanscolMedianscolMinscolMinsMaxscolnormal.mlecolnormlog.mlecolnthcolOrdercolpareto.mlecolPmaxcolPmincolpois.testscolpoisdisp.testscolpoisson.anovascolpoisson.mlecolprodscolquasipoisson.anovascolrangecolRankscolrayleigh.mlecolrint.regbxcolrow.valuecolShufflecolskewnesscolSortcolsumscolTabulatecolTruecolTrueFalsecolumnscolvarcomps.mlecolvarcomps.momcolVarscolvm.mlecolwatsonscolweibull.mlecomb_ncor.fbedcor.fsregcoracorpairscorrelscount_valuecovacox.poisratcqtestcqtestsCrossprodct.mledata.frame.to_matrixdcordcor.ttestdcovdesign_matrixDiag.fillDiag.matrixDigammadiri.nr2dirimultinom.mledirknndirknn.cvDistdistadmvnormdmvtdvareachcol.applyeachrowedisteel.test1eel.test2eigen.symel.test1el.test2ElemElem<-env.copyexact.ttest2exp2.mleexpmleexpregsfish.kentfloydfoldnorm.mlefreq.maxfreq.minfs.regftestftestsg2Testg2Test_permg2Test_univariateg2Test_univariate_permg2testsg2tests_permgammacongammamlegammanbgammanb.predgammareggammaregsgaussian.nbgaussiannb.predgchi2Testgeom.anovageom.anovasgeom.mlegeom.nbgeom.regsgeomnb.predginisglm_logisticglm_poissongroupgroup.sumgroupcorrelsgumbel.mlehalfnorm.mleHashhash.findHash.key.multihash.listhash2listhd.eigenhsecant01.mleiag.mleibeta.mleinvdir.mleinvgauss.mleinvgauss.reginvgauss.regsis_elementis_integeris.symmetriciteratorjamesknnknn.cvkruskaltestkruskaltestskuiperkurtkurt.test2laplace.mleLbetaLchooseLgammalindley.mlelist.ftestslmfitLoglogcauchy.mlelogistic_onlylogistic.cat1logistic.mlelogitnorm.mleloglogistic.mlelognorm.mlelogseries.mlelomax.mlelower_trilower_tri.assignMadmahalamat.matmat.multMatchmatch.coefsmatrnormmaxboltz.mlemcnemarmcnemarsmedMedianmediandirmin_maxmultinom.mlemultinom.nbmultinom.regmultinom.regsmultinomnb.predmultivmf.mlemv.eeltest1mv.eeltest2mvbetasmvkurtosismvlnorm.mlemvnorm.mlemvt.mlenegativenegbin.mleNormnormal.mlenormlog.mlenormlog.regnormlog.regsnthoddsodds.ratioompomprOrderordinal.mleOuterpareto.mlepc.skelpercent.ttestpercent.ttestspermcorpermutationpermutation.nextpermutation.prevPmaxPminPmin_Pmaxpois.testpoisdisp.testpoisson_onlypoisson.anovapoisson.anovaspoisson.cat1poisson.mlepoisson.nbpoissonnb.predpoly.corpooled.covpositivepositive.negativeprop.regprop.regsproptestproptestsqpois.regqpois.regsquasi.poisson_onlyquasipoisson.anovaquasipoisson.anovasracgRankrayleigh.mlerbingrbinghamread.directoryread.examplesregressionrel.riskRemoveFromNamespacerep_colrep_rowrint.mlerint.regrint.regbxrint.regsrm.anovarm.anovasrm.linesrmdprmvlaplacermvnormrmvtRnormRoundrowAllrowAnyrowCountValuesrowcvsrowFalserowhameansrowMadsrowMaxsrowmeansrowMediansrowMinsrowMinsMaxsrownthrowOrderrowprodsrowrangerowRanksrowsrowShufflerowSortrowsumsrowTabulaterowTruerowTrueFalserowVarsrvmfrvonmisesscore.betaregsscore.expregsscore.gammaregsscore.geomregsscore.glmsscore.invgaussregsscore.multinomregsscore.negbinregsscore.weibregsscore.ztpregssftestsftestsskewskew.test2Sortsort_cor_vectorssort_matsort_uniquesort_unique.lengthSort.intsourceRsourceRdspat.medspatmed.regspdinvspml.mlespml.regspml.regssquareformsscovStackstandardisesubmatrixTableTable.signTcrossprodtmletobit.mletopological_sorttotal.disttotal.distatransposeTrigammattestttest1ttest2tteststtests.pairstwoway.anovatwoway.anovasufactorunivglmsunivglms2upper_triupper_tri.assignVarvar2testvar2testsvarcomps.mlevarcomps.momvartestvartestsvecdistvm.mlevmf.mlewatsonweib.regweibull.mlewhich.iswigner.mlewrapcauchy.mleXopY.sumyulezip.mleztp.mle

Dependencies:RcppRcppArmadilloRcppGSLRcppParallelRcppZiggurat

Readme and manuals

Help Manual

Help pageTopics
A Collection of Efficient and Extremely Fast R FunctionsRfast-package
All k possible combinations from n elementscomb_n
Analysis of covarianceancova1
Analysis of variance with a count variablegeom.anova poisson.anova quasipoisson.anova
Angular central Gaussian random values simulationracg
ANOVA for two quasi Poisson regression modelsanova_quasipois.reg
Apply method to Positive and Negative numbernegative positive positive.negative
Apply to each column a method under conditionapply.condition
Backward selection regressionbs.reg
BIC (using partial correlation) forward regressionbic.corfsreg
BIC forward regression with generalised linear modelsbic.fs.reg
Binary search algorithmbinary_search
Binomial coefficient and its logarithmChoose Lchoose
Bootstrap t-test for 2 independent samplesboot.ttest2
Check if any column or row is fill with valuescolrow.value
Check if values are integers and convert to integeras_integer is_integer
Check Namespace and Rd filescheckAliases checkExamples checkNamespace checkTF checkUsage
Check whether a square matrix is symmetricis.symmetric
Chi-square and G-square tests of (unconditional) indepdencegchi2Test
Cholesky decomposition of a square matrixcholesky
Circular or angular regressionspml.reg
Circular-linear correlationcirclin.cor
Coefficient matrices.coeff
Colum-wise cumulative operations (sum, prod, min, max)colCumMaxs colCumMins colCumProds colCumSums
Column and row wise coefficients of variationcolcvs rowcvs
Column and row-wise AnycolAll colAny rowAll rowAny
Column and row-wise means of a matrixcolhameans colmeans colmeans.data.frame colmeans.matrix rowhameans rowmeans
Column and row-wise medians of a matrix or median of a vector.colMedians med Median rowMedians
Column and row-wise nth smallest value of a matrix/vectorcolnth nth rownth
Column and row-wise Order - Sort IndicescolOrder Order rowOrder
Column and row-wise productscolprods rowprods
Column and row-wise range of values of a matrix.colrange rowrange
Column and row-wise rankscolRanks Rank rowRanks
Column and row-wise ShufflecolShuffle rowShuffle
Column and row-wise sums of a matrixcolsums rowsums
Column and row-wise tabulatecolTabulate rowTabulate
Column and row-wise variances and standard deviations of a matrixcolVars colVars.data.frame colVars.matrix rowVars
Column and row-wise mean absolute deviationscolMads Mad rowMads
Column-wise differencescoldiffs
Column-wise kurtosis and skewness coefficientscolkurtosis colskewness
Column-wise matching coefficientsmatch.coefs
Column-wise minimum and maximum of a matrixcolMaxs colMins colMinsMaxs
Column-wise MLE of some univariate distributionscolexp2.mle colexpmle colgammamle colinvgauss.mle collaplace.mle collindley.mle colmaxboltz.mle colnormal.mle colnormlog.mle colpareto.mle colrayleigh.mle colvm.mle colweibull.mle
Column-wise true/false value of a matrixcolFalse colTrue colTrueFalse
Column-wise uniformity tests for circular datacolwatsons
Column-wise Yule's Y (coefficient of colligation)col.yule
Convert a dataframe to matrixdata.frame.to_matrix
Convert R function to the Rfast's corespondingas.Rfast.function
Correlation based forward regression.cor.fsreg
Correlation between pairs of variablescorpairs
Correlation between a vector and a set of variablescorrels groupcorrels
Fast covariance and correlation matrix calculationcora cova
Cox confidence interval for the ratio of two Poisson variablescol.coxpoisrat cox.poisrat
Cross-Validation for the k-NN algorithmknn.cv
Cross-Validation for the k-NN algorithm using the arc cosinus distancedirknn.cv
Deep copyenv.copy
Density of the multivariate normal and t distributionsdmvnorm dmvt
Design Matrixdesign_matrix
Diagonal MatrixDiag.fill Diag.matrix
Distance between vectors and a matrix - Sum of all pairwise distances in a distance matrix.dista total.dista
Distance correlationbcdcor dcor
Distance matrix - Sum of all pairwise distances in a distance matrixDist total.dist vecdist
Distance variance and covariancedcov dvar
Eigenvalues in high dimensional principal component analysishd.eigen
Empirical and exponential empirical likelihood tests for one sampleeel.test1 el.test1
Empirical and exponential empirical likelihood tests for two sampleseel.test2 el.test2
Energy distance between matricesedist
Equality of objectsall_equals
Estimation of an AR(1) modelar1 colar1
Estimation of the Box-Cox transformationbc
Exact t-test for 2 independent samplesexact.ttest2
Exponential empirical likelihood for a one sample mean vector hypothesis testingmv.eeltest1
Exponential empirical likelihood hypothesis testing for two mean vectorsmv.eeltest2
Fast and general represantation of a factor variableprint.ufactor ufactor [.ufactor
FBED variable selection method using the correlationcor.fbed
Find elementis_element
Find the given value in a hash tablehash.find
Fitted probabilities of the Terry-Bradley modelbtmprobs
Fitting a Dirichlet distribution via Newton-Rapshondiri.nr2
Floyd-Warshall algorithm for shortest paths in a directed graphfloyd
Variable selection in generalised linear regression models with forward selectionfs.reg
G-square test of conditional indepdencechi2Test g2Test g2Test_perm
Gamma regression with a log-linkgammacon gammareg
Gaussian regression with a log-linknormlog.reg
Generates random values from a normal and puts them in a matrixmatrnorm
Get specific columns/rows fo a matrixcolumns rows
Hash - Pair functionhash.list
Hash objectHash Hash.key.multi length.Hash print.Hash [.Hash [<-.Hash
Hash object to a list objecthash2list
High dimensional MCD based detection of outliersrmdp
Hypothesis test for the distance correlationdcor.ttest
Hypothesis test for two means of percentagespercent.ttest
Hypothesis test for von Mises-Fisher distribution over Kent distributionfish.kent
Hypothesis testing between two skewness or kurtosis coefficientskurt.test2 skew.test2
Index of the columns of a data.frame which are a specific typewhich.is
Insert/remove function names in/from the NAMESPACE fileAddToNamespace RemoveFromNamespace
Inverese Gaussian regression with a log-linkinvgauss.reg
Inverse of a symmetric positive definite matrixspdinv
Iterator!=.iterator ==.iterator Elem Elem.iterator Elem<- Elem<-.iterator iterator print.iterator
James multivariate version of the t-testjames
k nearest neighbours algorithm (k-NN)knn
k-NN algorithm using the arc cosinus distancedirknn
Limited number of eigenvalues and eigenvectors of a symmetric matrixeigen.sym
Linear models for large scale datalmfit
Logistic and Poisson regression modelsglm_logistic glm_poisson
Logistic or Poisson regression with a single categorical predictorlogistic.cat1 poisson.cat1
Lower and Upper triangular of a matrixlower_tri lower_tri.assign upper_tri upper_tri.assign
Mahalanobis distancemahala
Many area under the curve valuesauc colaucs
Many 2 sample proportions testsproptests
Many 2 sample tests testsmcnemars ttests var2tests
Many analysis of variance tests with a discrete variablegeom.anovas poisson.anovas quasipoisson.anovas
Many ANCOVAsancovas
Many ANOVAS for count data with Poisson or quasi Poisson modelscolpoisson.anovas colquasipoisson.anovas
Many exponential regressionsexpregs
Many F-tests with really huge matriceslist.ftests
Many G-square tests of indepedencechi2tests g2tests g2tests_perm
Many Gini coefficientsginis
Many hypothesis tests for two means of percentagespercent.ttests
Many moment and maximum likelihood estimations of variance componentscolvarcomps.mle colvarcomps.mom
Many multi-sample testsanovas block.anovas ftests vartests
Many multivariate simple linear regressions coefficientsmvbetas
Many multi-sample testscqtests kruskaltests
Many odds ratio testsodds
Many one sample goodness of fit tests for categorical datacat.goftests
Many one sample testsproptest ttest vartest
Many random intercepts LMMs for balanced data with a single identical covariatecolrint.regbx
Many regression based tests for single sample repeated measuresrm.anovas rm.lines
Many score based regressionsscore.betaregs score.expregs score.gammaregs score.geomregs score.glms score.invgaussregs score.multinomregs score.negbinregs score.weibregs score.ztpregs
Many Shapiro-Francia normality testssftest sftests
Many simple circular or angular regressionsspml.regs
Many simple geometric regressions.geom.regs
Many simple linear mixed model regressionsrint.regs
Simple linear regressions coefficientsallbetas
Many simple multinomial regressions.multinom.regs
Many simple regressions for positive valued datagammaregs invgauss.regs normlog.regs
Many tests for the dispersion parameter in Poisson distributioncolpois.tests colpoisdisp.tests
Many two-way ANOVAstwoway.anovas
Many univariate generalised linear regressionsunivglms univglms2
Many univariate simple linear regressionsregression
Many univariate simple binary logistic regressionslogistic_only poisson_only
Many univariate simple poisson regressionsquasi.poisson_only
Many Welch's F-testscolanovas
MatchMatch
Matrix multiplication, Cross and Tcross product.Crossprod mat.mult Tcrossprod
Matrix with all pairs of t-testsallttests ttests.pairs
Matrix with G-square tests of indepdencechi2Test_univariate g2Test_univariate g2Test_univariate_perm
Minima and maxima of two vectors/matrices and Column-row wise minima and maxima of two matricescolPmax colPmin Pmax Pmin Pmin_Pmax
Minimum and maximum of a vectormin_max
Minimum and maximum frequencies of a vectorfreq.max freq.min
MLE for multivariate discrete datacolgeom.mle colpoisson.mle dirimultinom.mle multinom.mle
MLE of (hyper-)spherical distributionsacg.mle iag.mle multivmf.mle vmf.mle
MLE of continuous univariate distributions defined on the positive linebetaprime.mle chisq.mle exp2.mle expmle foldnorm.mle gammamle halfnorm.mle invgauss.mle lindley.mle logcauchy.mle loglogistic.mle lognorm.mle lomax.mle maxboltz.mle normlog.mle pareto.mle rayleigh.mle weibull.mle
MLE of continuous univariate distributions defined on the real linecauchy.mle ct.mle gumbel.mle laplace.mle logistic.mle normal.mle tmle wigner.mle
MLE of count databetabinom.mle betageom.mle binom.mle borel.mle geom.mle logseries.mle negbin.mle poisson.mle zip.mle ztp.mle
MLE of distributions defined in the (0, 1) intervalbeta.mle hsecant01.mle ibeta.mle logitnorm.mle
MLE of some circular distributionsspml.mle vm.mle wrapcauchy.mle
MLE of the inverted Dirichlet distributioninvdir.mle
MLE of the multivariate (log-) normal distributionmvlnorm.mle mvnorm.mle
MLE of the multivariate t distributionmvt.mle
MLE of the ordinal model without covariatesordinal.mle
MLE of the tobit modeltobit.mle
Moment and maximum likelihood estimation of variance componentsrint.mle varcomps.mle varcomps.mom
Multi-sample tests for vectorsanova1 block.anova cqtest ftest kruskaltest mcnemar ttest2 twoway.anova var2test
Multinomial regressionmultinom.reg
Multivariate kurtosismvkurtosis
Multivariate Laplace random values simulationrmvlaplace
Multivariate normal and t random values simulationrmvnorm rmvt
Naive Bayes classifiersgammanb gaussian.nb geom.nb multinom.nb poisson.nb
Natural Logarithm each element of a matrixLog
Natural logarithm of the beta functionLbeta
Natural logarithm of the gamma function and its derivatives.Digamma Lgamma Trigamma
Norm of a matrixNorm
Number of equal columns between two matricesmat.mat
Odds ratio and relative riskodds.ratio rel.risk
One sample t-test for a vectorttest1
Operations between two matrices or matrix and vectoreachcol.apply eachrow XopY.sum
Orthogonal matching pursuit variable selectionomp ompr
Outer functionOuter
Permutationbincomb permutation permutation.next permutation.prev
Permutation based p-value for the Pearson correlation coefficientpermcor
Polyserial correlationpoly.cor
Pooled covariance matrixpooled.cov
Prediction with some naive Bayes classifiersgammanb.pred gaussiannb.pred geomnb.pred multinomnb.pred poissonnb.pred
Quasi binomial regression for proportionsprop.reg prop.regs
Quasi Poisson regressionqpois.reg qpois.regs
Random intercepts linear mixed modelsrint.reg rint.regbx
Random values simulation from a von Mises distributionrvonmises
Reading the files of a directoryread.directory read.examples
Repeated measures anovarm.anova
Replicate columns/rowsrep_col rep_row
Represantation of StackStack
Round each element of a matrix/vectorRound
Row - Wise matrix/vector count the frequency of a valuecolCountValues count_value rowCountValues
Row-wise minimum and maximum of a matrix.rowMaxs rowMins rowMinsMaxs
Row-wise true value of a matrixrowFalse rowTrue rowTrueFalse
Search for variables with zero range in a matrixcheck_data
Significance testing for the coefficients of Quasi binomial or the quasi Poisson regressionanova_propreg anova_qpois.reg
Simulating from a Bingham distributionrbing
Simulation of random values from a Bingham distribution with any symmetric matrixrbingham
Simulation of random values from a normal distributionRnorm
Random values simulation from a von Mises-Fisher distributionrvmf
The skeleton of a Bayesian network produced by the PC algorithmpc.skel
Skewness and kurtosis coefficientskurt skew
Some summary statistics of a vector for each level of a grouping variable.group group.sum
Sort - Integer Sort - Sort a vector coresponding to anotherSort Sort.int sort_cor_vectors
Sort and uniquesort_unique sort_unique.length
Sorting of the columns-rows of a matrixcolSort rowSort sort_mat
Source many R filessourceR sourceRd
Spatial median for Euclidean dataspat.med
Spatial median regressionspatmed.reg
Spatial sign covariance matrixsscov
Fast calculation of the spherical and hyperspherical medianmediandir
Standardisationstandardise
Sub-matrixsubmatrix
Table Creation - Frequency of each valueTable Table.sign
Tests for the dispersion parameter in Poisson distributionpois.test poisdisp.test
Topological sort of a DAGtopological_sort
Transpose of a matrixtranspose
Uniformity tests for circular datakuiper watson
Variance (and standard deviation) of a vectorVar
Vector allocation in a symmetric matrixsquareform
Weibull regression modelweib.reg
Yule's Y (coefficient of colligation)yule