Package: caret 6.0-94

caret: Classification and Regression Training

Misc functions for training and plotting classification and regression models.

Authors:Max Kuhn [aut, cre], Jed Wing [ctb], Steve Weston [ctb], Andre Williams [ctb], Chris Keefer [ctb], Allan Engelhardt [ctb], Tony Cooper [ctb], Zachary Mayer [ctb], Brenton Kenkel [ctb], R Core Team [ctb], Michael Benesty [ctb], Reynald Lescarbeau [ctb], Andrew Ziem [ctb], Luca Scrucca [ctb], Yuan Tang [ctb], Can Candan [ctb], Tyler Hunt [ctb]

caret_6.0-94.tar.gz
caret_6.0-94.zip(r-4.5)caret_6.0-94.zip(r-4.4)caret_6.0-94.zip(r-4.3)
caret_6.0-94.tgz(r-4.4-x86_64)caret_6.0-94.tgz(r-4.4-arm64)caret_6.0-94.tgz(r-4.3-x86_64)caret_6.0-94.tgz(r-4.3-arm64)
caret_6.0-94.tar.gz(r-4.5-noble)caret_6.0-94.tar.gz(r-4.4-noble)
caret_6.0-94.tgz(r-4.4-emscripten)caret_6.0-94.tgz(r-4.3-emscripten)
caret.pdf |caret.html
caret/json (API)
NEWS

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

Peer review:

Bug tracker:https://github.com/topepo/caret/issues

Datasets:
  • GermanCredit - German Credit Data
  • Sacramento - Sacramento CA Home Prices
  • absorp - Fat, Water and Protein Content of Meat Samples
  • bbbDescr - Blood Brain Barrier Data
  • cars - Kelly Blue Book resale data for 2005 model year GM cars
  • cox2Class - COX-2 Activity Data
  • cox2Descr - COX-2 Activity Data
  • cox2IC50 - COX-2 Activity Data
  • dhfr - Dihydrofolate Reductase Inhibitors Data
  • endpoints - Fat, Water and Protein Content of Meat Samples
  • fattyAcids - Fatty acid composition of commercial oils
  • logBBB - Blood Brain Barrier Data
  • mdrrClass - Multidrug Resistance Reversal (MDRR) Agent Data
  • mdrrDescr - Multidrug Resistance Reversal (MDRR) Agent Data
  • oilType - Fatty acid composition of commercial oils
  • potteryClass - Pottery from Pre-Classical Sites in Italy
  • scat - Morphometric Data on Scat
  • scat_orig - Morphometric Data on Scat
  • segmentationData - Cell Body Segmentation

On CRAN:

18.87 score 1.6k stars 287 packages 56k scripts 202k downloads 630 mentions 179 exports 74 dependencies

Last updated 2 years agofrom:5f4bd2069b. Checks:OK: 1 NOTE: 8. Indexed: yes.

TargetResultDate
Doc / VignettesOKNov 06 2024
R-4.5-win-x86_64NOTENov 06 2024
R-4.5-linux-x86_64NOTENov 06 2024
R-4.4-win-x86_64NOTENov 06 2024
R-4.4-mac-x86_64NOTENov 06 2024
R-4.4-mac-aarch64NOTENov 06 2024
R-4.3-win-x86_64NOTENov 06 2024
R-4.3-mac-x86_64NOTENov 06 2024
R-4.3-mac-aarch64NOTENov 06 2024

Exports:anovaScoresavNNetbagbagControlbagEarthbagEarthStatsbagFDAbestBoxCoxTranscalibrationcaretFuncscaretGAcaretSAcaretSBFcaretThemecforestStatscheckConditionalXcheckInstallcheckResamplesclass2indclassDistclustercompare_modelsconfusionMatrixconfusionMatrix.traincontr.dummycontr.ltfrcreateDataPartitioncreateFoldscreateModelcreateMultiFoldscreateResamplecreateTimeSlicesctreeBagdefaultSummarydotPlotdownSampledummyVarsexpandParametersexpoTransextractPredictionextractProbF_measfeaturePlotfilterVarImpfindCorrelationfindLinearCombosflatTablegafsgafs_initialgafs_lrSelectiongafs_raMutationgafs_rwSelectiongafs_spCrossovergafs_tourSelectiongafs_uCrossovergafs.defaultgafsControlgamFormulagamFuncsgamScoresgetModelInfogetSamplingInfogetTrainPerfggplot.gafsggplot.safsgroupKFoldhasTermsicrindex2vecipredStatsknn3knn3TrainknnregknnregTrainldaBagldaFuncsldaSBFlearning_curve_datliftlmFuncslmSBFLPH07_1LPH07_2lrFuncsMAEmaxDissimMeanSDminDissmnLogLossmodelCormodelLookupmultiClassSummarynbBagnbFuncsnbSBFnearZeroVarnegPredValuennetBagnullModelnzvoneSEoutcome_conversionpanel.calibrationpanel.liftpanel.lift2panel.needlepcaNNetpickSizeBestpickSizeTolerancepickVarsplot.gafsplot.rfeplot.safsplot.trainplotClassProbsplotObsVsPredplsBagplsdaposPredValuepostResampleprecisionpredict.bagEarthpredict.gafspredict.trainpredictionFunctionpredictorspreProcessprint.trainprobFunctionprogressprSummaryR2recallresampleHistresamplesresampleSummaryresampleWrapperrferfeControlrfeIterrfFuncsrfGArfSArfSBFrfStatsRMSEsafssafs_initialsafs_perturbsafs_probsafsControlsbfsbfControlsbfItersensitivitySLC14_1SLC14_2sortImpspatialSignspecificitysplsdasumDisssummary.bagEarthsvmBagthresholdertolerancetraintrainControltreebagFuncstreebagGAtreebagSAtreebagSBFtwoClassSimtwoClassSummaryupSamplevar_seqvarImpwell_numbered

Dependencies:classcliclockcodetoolscolorspacecpp11data.tablediagramdigestdplyre1071fansifarverforeachfuturefuture.applygenericsggplot2globalsgluegowergtablehardhatipredisobanditeratorsKernSmoothlabelinglatticelavalifecyclelistenvlubridatemagrittrMASSMatrixmgcvModelMetricsmunsellnlmennetnumDerivparallellypillarpkgconfigplyrpROCprodlimprogressrproxypurrrR6RColorBrewerRcpprecipesreshape2rlangrpartscalesshapeSQUAREMstringistringrsurvivaltibbletidyrtidyselecttimechangetimeDatetzdbutf8vctrsviridisLitewithr

A Short Introduction to the caret Package

Rendered fromcaret.Rmdusingknitr::rmarkdownon Nov 06 2024.

Last update: 2021-10-08
Started: 2018-03-02

Readme and manuals

Help Manual

Help pageTopics
Confusion matrix as a tableas.matrix.confusionMatrix as.table.confusionMatrix
Neural Networks Using Model AveragingavNNet avNNet.default avNNet.formula predict.avNNet print.avNNet
A General Framework For Baggingbag bag.default bagControl ctreeBag ldaBag nbBag nnetBag plsBag predict.bag print.bag print.summary.bag summary.bag svmBag
Bagged EarthbagEarth bagEarth.default bagEarth.formula print.bagEarth
Bagged FDAbagFDA bagFDA.default bagFDA.formula print.bagFDA
Blood Brain Barrier DatabbbDescr BloodBrain logBBB
Box-Cox and Exponential TransformationsBoxCoxTrans BoxCoxTrans.default expoTrans expoTrans.default predict.BoxCoxTrans predict.expoTrans print.BoxCoxTrans
Probability Calibration Plotcalibration calibration.default calibration.formula ggplot.calibration panel.calibration print.calibration xyplot.calibration
Selection By Filtering (SBF) Helper FunctionsanovaScores caretSBF gamScores ldaSBF lmSBF nbSBF rfSBF treebagSBF
Kelly Blue Book resale data for 2005 model year GM carscars
Compute and predict the distances to class centroidsclassDist classDist.default predict.classDist
Create a confusion matrixconfusionMatrix confusionMatrix.default confusionMatrix.matrix confusionMatrix.table
Estimate a Resampled Confusion MatrixconfusionMatrix.rfe confusionMatrix.sbf confusionMatrix.train
COX-2 Activity Datacox2 cox2Class cox2Descr cox2IC50
Data Splitting functionscreateDataPartition createFolds createMultiFolds createResample createTimeSlices groupKFold
Calculates performance across resamplesdefaultSummary getTrainPerf MAE mnLogLoss multiClassSummary postResample prSummary R2 RMSE twoClassSummary
Lattice functions for plotting resampling results of recursive feature selectiondensityplot.rfe histogram.rfe stripplot.rfe xyplot.rfe
Dihydrofolate Reductase Inhibitors Datadhfr
Inferential Assessments About Model Performancecompare_models diff.resamples summary.diff.resamples
Create a dotplot of variable importance valuesdotPlot
Lattice Functions for Visualizing Resampling Differencesbwplot.diff.resamples densityplot.diff.resamples dotplot.diff.resamples levelplot.diff.resamples
Down- and Up-Sampling Imbalanced DatadownSample upSample
Create A Full Set of Dummy Variablesclass2ind contr.dummy contr.ltfr dummyVars dummyVars.default predict.dummyVars print.dummyVars
Extract predictions and class probabilities from train objectsextractPrediction extractProb predict.list predict.train
Wrapper for Lattice Plotting of Predictor VariablesfeaturePlot
Calculation of filter-based variable importancefilterVarImp
Determine highly correlated variablesfindCorrelation
Determine linear combinations in a matrixfindLinearCombos
Format 'bagEarth' objectsformat.bagEarth
Ancillary genetic algorithm functionscaretGA gafs_initial gafs_lrSelection gafs_nlrSelection gafs_raMutation gafs_rwSelection gafs_spCrossover gafs_tourSelection gafs_uCrossover rfGA treebagGA
Genetic algorithm feature selectiongafs gafs.default gafs.recipe
Control parameters for GA and SA feature selectiongafsControl safsControl
German Credit DataGermanCredit
Get sampling info from a train modelgetSamplingInfo
Plot RFE Performance Profilesggplot.rfe plot.rfe
Plot Method for the train Classggplot.train plot.train
Lattice functions for plotting resampling resultsdensityplot.train histogram.train stripplot.train xyplot.train
Independent Component Regressionicr icr.default icr.formula predict.icr
Convert indicies to a binary vectorindex2vec
k-Nearest Neighbour Classificationknn3 knn3.data.frame knn3.formula knn3.matrix knn3Train print.knn3
k-Nearest Neighbour Regressionknnreg knnreg.data.frame knnreg.default knnreg.formula knnreg.matrix knnregTrain print.knnreg
Create Data to Plot a Learning Curvelearning_curve_dat
Lift Plotggplot.lift lift lift.default lift.formula print.lift xyplot.lift
Maximum Dissimilarity SamplingmaxDissim minDiss sumDiss
Multidrug Resistance Reversal (MDRR) Agent Datamdrr mdrrClass mdrrDescr
Tools for Models Available in 'train'checkInstall getModelInfo modelLookup
Identification of near zero variance predictorscheckConditionalX checkResamples nearZeroVar nzv
Calculate sensitivity, specificity and predictive valuesnegPredValue negPredValue.default negPredValue.matrix negPredValue.table posPredValue posPredValue.default posPredValue.matrix posPredValue.table sensitivity sensitivity.default sensitivity.matrix sensitivity.table specificity specificity.default specificity.matrix specificity.table
Fit a simple, non-informative modelnullModel nullModel.default predict.nullModel
Fatty acid composition of commercial oilsfattyAcids oil oilType
Selecting tuning Parametersbest oneSE tolerance
Lattice Panel Functions for Lift Plotspanel.lift panel.lift2
Needle Plot Lattice Panelpanel.needle
Neural Networks with a Principal Component SteppcaNNet pcaNNet.default pcaNNet.formula predict.pcaNNet print.pcaNNet
Backwards Feature Selection Helper FunctionscaretFuncs gamFuncs ldaFuncs lmFuncs lrFuncs nbFuncs pickSizeBest pickSizeTolerance pickVars rfFuncs treebagFuncs
Plot Method for the gafs and safs Classesggplot.gafs ggplot.safs plot.gafs plot.safs
Plotting variable importance measuresggplot.varImp.train plot.varImp.train
Plot Predicted Probabilities in Classification ModelsplotClassProbs
Plot Observed versus Predicted Results in Regression and Classification ModelsplotObsVsPred
Partial Least Squares and Sparse Partial Least Squares Discriminant Analysisplsda plsda.default predict.plsda predict.splsda splsda splsda.default
Pottery from Pre-Classical Sites in Italypottery potteryClass
Principal Components Analysis of Resampling Resultscluster cluster.resamples plot.prcomp.resamples prcomp.resamples
Predicted values based on bagged Earth and FDA modelspredict.bagEarth predict.bagFDA
Predict new samplespredict.gafs predict.safs
Predictions from k-Nearest Neighborspredict.knn3
Predictions from k-Nearest Neighbors Regression Modelpredict.knnreg
List predictors used in the modelpredictors predictors.default predictors.formula predictors.list predictors.rfe predictors.sbf predictors.terms predictors.train
Pre-Processing of Predictorspredict.preProcess preProcess preProcess.default
Print method for confusionMatrixprint.confusionMatrix
Print Method for the train Classprint.train
Calculate recall, precision and F valuesF_meas F_meas.default F_meas.table precision precision.default precision.matrix precision.table recall recall.default recall.table
Plot the resampling distribution of the model statisticsresampleHist
Collation and Visualization of Resampling Resultsas.data.frame.resamples as.matrix.resamples modelCor print.resamples resamples resamples.default sort.resamples summary.resamples
Summary of resampled performance estimatesresampleSummary
Backwards Feature Selectionpredict.rfe rfe rfe.default rfe.formula rfe.recipe rfeIter update.rfe
Controlling the Feature Selection AlgorithmsrfeControl
Sacramento CA Home PricesSacramento
Simulated annealing feature selectionsafs safs.default safs.recipe
Ancillary simulated annealing functionscaretSA rfSA safs_initial safs_perturb safs_prob treebagSA
Selection By Filtering (SBF)predict.sbf sbf sbf.default sbf.formula sbf.recipe
Control Object for Selection By Filtering (SBF)sbfControl
Morphometric Data on Scatscat scat_orig
Cell Body SegmentationsegmentationData
Simulation FunctionsLPH07_1 LPH07_2 SLC14_1 SLC14_2 twoClassSim
Compute the multivariate spatial signspatialSign spatialSign.data.frame spatialSign.default spatialSign.matrix
Summarize a bagged earth or FDA fitsummary.bagEarth summary.bagFDA
Fat, Water and Protein Content of Meat Samplesabsorp endpoints tecator
Generate Data to Choose a Probability Thresholdthresholder
Fit Predictive Models over Different Tuning Parameterstrain train.default train.formula train.recipe
A List of Available Models in trainmodels train_model_list
Control parameters for traintrainControl
Update or Re-fit a SA or GA Modelupdate.gafs update.safs
Update or Re-fit a Modelupdate.train
Sequences of Variables for Tuningvar_seq
Calculation of variable importance for regression and classification modelsvarImp varImp.avNNet varImp.bagEarth varImp.bagFDA varImp.C5.0 varImp.classbagg varImp.cubist varImp.dsa varImp.earth varImp.fda varImp.Gam varImp.gam varImp.gbm varImp.glm varImp.glmnet varImp.JRip varImp.lm varImp.multinom varImp.mvr varImp.nnet varImp.pamrtrained varImp.PART varImp.plsda varImp.RandomForest varImp.randomForest varImp.regbagg varImp.rfe varImp.rpart varImp.RRF varImp.train
Variable importances for GAs and SAsvarImp.gafs varImp.safs
Lattice Functions for Visualizing Resampling Resultsbwplot.resamples densityplot.resamples dotplot.resamples ggplot.resamples parallelplot.resamples splom.resamples xyplot.resamples