{"id":26264285,"url":"https://github.com/AdrianAntico/RemixAutoML","last_synced_at":"2025-03-14T02:01:58.139Z","repository":{"id":37432080,"uuid":"148236733","full_name":"AdrianAntico/AutoQuant","owner":"AdrianAntico","description":"R package for automation of machine learning, forecasting, model evaluation, and model interpretation","archived":false,"fork":false,"pushed_at":"2024-08-19T19:44:41.000Z","size":842630,"stargazers_count":235,"open_issues_count":2,"forks_count":43,"subscribers_count":10,"default_branch":"master","last_synced_at":"2024-10-07T15:02:06.500Z","etag":null,"topics":["automated-machine-learning","automl","catboost","classification","gpu-acceleration","h2o","lightgbm","multiclass-classification","panel-data","r","regression","supervised-learning","timeseries","unsupervised-learning","xgboost"],"latest_commit_sha":null,"homepage":"","language":"R","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"agpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/AdrianAntico.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-09-11T00:27:27.000Z","updated_at":"2024-09-16T02:57:21.000Z","dependencies_parsed_at":"2023-09-29T08:00:25.826Z","dependency_job_id":"e4b8748f-e92c-4931-831d-b7b90b551726","html_url":"https://github.com/AdrianAntico/AutoQuant","commit_stats":null,"previous_names":["adrianantico/remixautoml"],"tags_count":52,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AdrianAntico%2FAutoQuant","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AdrianAntico%2FAutoQuant/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AdrianAntico%2FAutoQuant/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AdrianAntico%2FAutoQuant/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/AdrianAntico","download_url":"https://codeload.github.com/AdrianAntico/AutoQuant/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243510117,"owners_count":20302294,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["automated-machine-learning","automl","catboost","classification","gpu-acceleration","h2o","lightgbm","multiclass-classification","panel-data","r","regression","supervised-learning","timeseries","unsupervised-learning","xgboost"],"created_at":"2025-03-14T02:01:54.717Z","updated_at":"2025-03-14T02:01:58.126Z","avatar_url":"https://github.com/AdrianAntico.png","language":"R","funding_links":[],"categories":["R"],"sub_categories":[],"readme":"![Version: 1.0.0](https://img.shields.io/static/v1?label=Version\u0026message=1.0.0\u0026color=blue\u0026?style=plastic)\n![Build: Passing](https://img.shields.io/static/v1?label=Build\u0026message=passing\u0026color=brightgreen)\n[![Maintenance](https://img.shields.io/badge/Maintained%3F-yes-green.svg)](https://GitHub.com/Naereen/StrapDown.js/graphs/commit-activity)\n[![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg?style=default)](http://makeapullrequest.com)\n[![GitHub Stars](https://img.shields.io/github/stars/AdrianAntico/AutoQuant.svg?style=social)](https://github.com/AdrianAntico/AutoQuant)\n\n\u003cimg src=\"https://github.com/AdrianAntico/AutoQuant/blob/master/Images/AutoQuant.PNG?raw=true\" align=\"center\" width=\"800\" /\u003e\n\n\n## AutoQuant Reference Manual\n\n![AutoQuant Reference Manual](https://github.com/AdrianAntico/AutoQuant/tree/master/vignette)\n\nCompanion Packages:\n- ![Quantico](https://github.com/AdrianAntico/Quantico)\n- ![Rodeo](https://github.com/AdrianAntico/Rodeo)\n- ![AutoPlots](https://github.com/AdrianAntico/AutoPlots)\n\nTable of Contents\n- [Background](#background)\n- [Installation](#installation)\n\nDocumentation + Code Examples\n- [Supervised Learning](#supervised-learning-)\n- [Model Scoring](#model-scoring-)\n- [Model Evaluation](#model-evaluation-)\n- [Panel Data Forecasting](#panel-data-forecasting-)\n- [Time Series Forecasting](#time-series-forecasting-)\n\n\n## Background\n\n\u003cdetails\u003e\u003csummary\u003eExpand to view content\u003c/summary\u003e\n\u003cp\u003e\n\n\u003e Automated Machine Learning - In my view, AutoML should consist of functions to help make professional model development and operationalization more efficient. The functions in this package are there to help no matter which part of the ML lifecycle you are working on. The functions in this package have been tested across a variety of industries and have consistently outperformed competing methods. \n\n### Package Details\n\u003e Supervised Learning - Currently, I'm utilizing CatBoost, LightGBM, XGBoost, and H2O for all of the automated Machine Learning related functions. GPU's can be utilized with CatBoost, LightGBM, and XGBoost, while those and the H2O models can all utilize 100% of CPU. Multi-armed bandit grid tuning is available for CatBoost, LightGBM, and XGBoost models, which utilize the concept of randomized probability matching, which is detailed in the R pacakge \"bandit\". My choice of included ML algorithms in the package is based on previous success when compared against other algorithms on real world use cases, the additional utilities these packages offer aside from accurate predictions, their ability to work on big data, and the fact that they're available in both R and Python which makes managing multiple languages a little more seamless in a professional setting.\n\n\u003e Documentation - Each exported function in the package has a help file and can be viewed in your RStudio session, e.g. \u003ccode\u003e?Rodeo::ModelDataPrep\u003c/code\u003e. Many of them come with examples coded up in the help files (at the bottom) that you can run to get a feel for how to set the parameters. There's also a listing of exported functions by category with code examples at the bottom of this readme. You can also jump into the R folder here to dig into the source code. \n\n\u003e Overall process: Typically, I go to the warehouse to get all of my base features and then I run through all the relevant feature engineering functions in this package. Personally, I set up templates for features engineering, model training optimization, and model scoring (including feature engineering for scoring). I collect all relevant metdata in a list that is shared across templates and as a result, I never have to touch the model scoring template, which makes operationalize and maintenace a breeze. I can simply list out the columns of interest, which feature engineering functions I want to utilize, and then I simply kick off some command line scripts and everything else is automatically managed.\n\n\u003c/p\u003e\n\u003c/details\u003e\n\n## Installation\n\nThe Description File is designed to require only the minimum number of packages to install AutoQuant. However, in order to utilize most of the functions in the package, you'll have to install additional libraries. I set it up this way on purpose. You don't need to install every single possible dependency if you are only interested in using a few of the functions. For example, if you only want to use CatBoost then install the catboost package and forget about the h2o, xgboost, and lightgbm packages. This is one of the primary benefits of not hosting an R package on cran, as they require dependencies to be part of the Imports section on the Description File, which subsequently requires users to have all dependencies installed in order to install the package.\n\nThe minimal set of packages that need to be installed are below. The full list can be found by expanding the section (Expand to view content).\n* bit64\n* data.table\n* doParallel\n* foreach\n* lubridate\n* timeDate\n\n```r\n\n# Core pacakges\nif(!(\"data.table\" %in% rownames(installed.packages()))) install.packages(\"data.table\"); print(\"data.table\")\nif(!(\"collapse\" %in% rownames(installed.packages()))) install.packages(\"collapse\"); print(\"collapse\")\nif(!(\"bit64\" %in% rownames(installed.packages()))) install.packages(\"bit64\"); print(\"bit64\")\nif(!(\"devtools\" %in% rownames(installed.packages()))) install.packages(\"devtools\"); print(\"devtools\")\nif(!(\"doParallel\" %in% rownames(installed.packages()))) install.packages(\"doParallel\"); print(\"doParallel\")\nif(!(\"foreach\" %in% rownames(installed.packages()))) install.packages(\"foreach\"); print(\"foreach\")\nif(!(\"lubridate\" %in% rownames(installed.packages()))) install.packages(\"lubridate\"); print(\"lubridate\")\nif(!(\"timeDate\" %in% rownames(installed.packages()))) install.packages(\"timeDate\"); print(\"timeDate\")\n\n# AutoQuant\ndevtools::install_github('AdrianAntico/AutoQuant', upgrade = FALSE, dependencies = FALSE, force = TRUE)\n```\n\n\u003cdetails\u003e\u003csummary\u003eAdditional Packages to Install\u003c/summary\u003e\n\u003cp\u003e\n\n#### Install ALL R package dependencies for all functions: \nXGBoost and LightGBM can be used with GPU. However, their installation is much more involved than CatBoost, which comes with GPU capabilities simply by installing their package. The installation instructions for them below is for the CPU version only. Refer to each's home page for instructions for installing for GPU. \n \n```r\n# Install Dependencies----\nif(!(\"devtools\" %in% rownames(installed.packages()))) install.packages(\"devtools\"); print(\"devtools\")\n\n# Core pacakges\nif(!(\"data.table\" %in% rownames(installed.packages()))) install.packages(\"data.table\"); print(\"data.table\")\nif(!(\"collapse\" %in% rownames(installed.packages()))) install.packages(\"collapse\"); print(\"collapse\")\nif(!(\"bit64\" %in% rownames(installed.packages()))) install.packages(\"bit64\"); print(\"bit64\")\nif(!(\"devtools\" %in% rownames(installed.packages()))) install.packages(\"devtools\"); print(\"devtools\")\nif(!(\"doParallel\" %in% rownames(installed.packages()))) install.packages(\"doParallel\"); print(\"doParallel\")\nif(!(\"foreach\" %in% rownames(installed.packages()))) install.packages(\"foreach\"); print(\"foreach\")\nif(!(\"lubridate\" %in% rownames(installed.packages()))) install.packages(\"lubridate\"); print(\"lubridate\")\nif(!(\"timeDate\" %in% rownames(installed.packages()))) install.packages(\"timeDate\"); print(\"timeDate\")\n\n# Additional dependencies for specific use cases\nif(!(\"combinat\" %in% rownames(installed.packages()))) install.packages(\"combinat\"); print(\"combinat\")\nif(!(\"DBI\" %in% rownames(installed.packages()))) install.packages(\"DBI\"); print(\"DBI\")\nif(!(\"e1071\" %in% rownames(installed.packages()))) install.packages(\"e1071\"); print(\"e1071\")\nif(!(\"fBasics\" %in% rownames(installed.packages()))) install.packages(\"fBasics\"); print(\"fBasics\")\nif(!(\"forecast\" %in% rownames(installed.packages()))) install.packages(\"forecast\"); print(\"forecast\")\nif(!(\"fpp\" %in% rownames(installed.packages()))) install.packages(\"fpp\"); print(\"fpp\")\nif(!(\"ggplot2\" %in% rownames(installed.packages()))) install.packages(\"ggplot2\"); print(\"ggplot2\")\nif(!(\"gridExtra\" %in% rownames(installed.packages()))) install.packages(\"gridExtra\"); print(\"gridExtra\")\nif(!(\"itertools\" %in% rownames(installed.packages()))) install.packages(\"itertools\"); print(\"itertools\")\nif(!(\"MLmetrics\" %in% rownames(installed.packages()))) install.packages(\"MLmetrics\"); print(\"MLmetrics\")\nif(!(\"nortest\" %in% rownames(installed.packages()))) install.packages(\"nortest\"); print(\"nortest\")\nif(!(\"pROC\" %in% rownames(installed.packages()))) install.packages(\"pROC\"); print(\"pROC\")\nif(!(\"RColorBrewer\" %in% rownames(installed.packages()))) install.packages(\"RColorBrewer\"); print(\"RColorBrewer\")\nif(!(\"recommenderlab\" %in% rownames(installed.packages()))) install.packages(\"recommenderlab\"); print(\"recommenderlab\")\nif(!(\"RPostgres\" %in% rownames(installed.packages()))) install.packages(\"RPostgres\"); print(\"RPostgres\")\nif(!(\"Rfast\" %in% rownames(installed.packages()))) install.packages(\"Rfast\"); print(\"Rfast\")\nif(!(\"scatterplot3d\" %in% rownames(installed.packages()))) install.packages(\"scatterplot3d\"); print(\"scatterplot3d\")\nif(!(\"stringr\" %in% rownames(installed.packages()))) install.packages(\"stringr\"); print(\"stringr\")\nif(!(\"tsoutliers\" %in% rownames(installed.packages()))) install.packages(\"tsoutliers\"); print(\"tsoutliers\")\nif(!(\"xgboost\" %in% rownames(installed.packages()))) install.packages(\"xgboost\"); print(\"xgboost\")\nif(!(\"lightgbm\" %in% rownames(installed.packages()))) install.packages(\"lightgbm\"); print(\"lightgbm\")\nif(!(\"regmedint\" %in% rownames(installed.packages()))) install.packages(\"regmedint\"); print(\"regmedint\")\nfor(pkg in c(\"RCurl\",\"jsonlite\")) if (! (pkg %in% rownames(installed.packages()))) { install.packages(pkg) }\ninstall.packages(\"h2o\", type = \"source\", repos = (c(\"http://h2o-release.s3.amazonaws.com/h2o/latest_stable_R\")))\ndevtools::install_github('catboost/catboost', subdir = 'catboost/R-package')\n\n# Dependencies for ML Reports\nif(!(\"reactable\" %in% rownames(installed.packages()))) install.packages(\"reactable\"); print(\"reactable\")\ndevtools::install_github('AdrianAntico/prettydoc', upgrade = FALSE, dependencies = FALSE, force = TRUE)\n\n# And lastly, AutoQuant\ndevtools::install_github('AdrianAntico/AutoQuant', upgrade = FALSE, dependencies = FALSE, force = TRUE)\n```\n\n#### Installation Troubleshooting \nThe most common issue some users are having when trying to install \u003ccode\u003eAutoQuant\u003c/code\u003e is the installation of the \u003ccode\u003ecatboost\u003c/code\u003e package dependency. Since \u003ccode\u003ecatboost\u003c/code\u003e is not on CRAN it can only be installed through GitHub. To install \u003ccode\u003ecatboost\u003c/code\u003e without error (and consequently install \u003ccode\u003eAutoQuant\u003c/code\u003e without error), try running this line of code first, then restart your R session, then re-run the 2-step installation process above. (\u003ca href=\"https://github.com/catboost/catboost/issues/612\" target=\"_blank\"\u003eReference\u003c/a\u003e):\nIf you're still having trouble submit an issue and I'll work with you to get it installed.\n\n```r\n# Method for on premise servers\noptions(devtools.install.args = c(\"--no-multiarch\", \"--no-test-load\"))\ninstall.packages(\"https://github.com/catboost/catboost/releases/download/\u003cversion\u003e/catboost-R-Windows-\u003cversion\u003e.tgz\", repos = NULL, type = \"source\", INSTALL_opts = c(\"--no-multiarch\", \"--no-test-load\"))\n\n# Method for azure machine learning Designer pipelines\n\n## catboost\ninstall.packages(\"https://github.com/catboost/catboost/releases/download/\u003cversion\u003e/catboost-R-Windows-\u003cversion\u003e.tgz\", repos = NULL, type = \"source\", INSTALL_opts = c(\"--no-multiarch\", \"--no-test-load\"))\n\n## AutoQuant\ninstall.packages(\"https://github.com/AdrianAntico/AutoQuant/archive/refs/tags/\u003cversion\u003e.tar.gz\", repos = NULL, type = \"source\", INSTALL_opts = c(\"--no-multiarch\", \"--no-test-load\"))\n```\n \n\n\u003c/p\u003e\n\u003c/details\u003e\n\n# Usage\n\n\n## Supervised Learning \u003cimg src=\"https://raw.githubusercontent.com/AdrianAntico/AutoQuant/master/Images/SupervisedLearningImage.png\" align=\"right\" width=\"80\" /\u003e\n\n\u003cdetails\u003e\u003csummary\u003eExpand to view content\u003c/summary\u003e\n\u003cp\u003e\n\n\n\n### Regression\n\n\u003cdetails\u003e\u003csummary\u003eclick to expand\u003c/summary\u003e\n\u003cp\u003e\n\n\u003cdetails\u003e\u003csummary\u003eRegression Description\u003c/summary\u003e\n\u003cp\u003e\n  \nThe Auto_Regression() models handle a multitude of tasks. In order:\n1. Convert your data to data.table format for faster processing\n2. Transform your target variable using the best normalization method based on the \u003ccode\u003eAutoTransformationCreate()\u003c/code\u003e function\n3. Create train, validation, and test data, utilizing the \u003ccode\u003eAutoDataPartition()\u003c/code\u003e function, if you didn't supply those directly to the function\n4. Consoldate columns that are used for modeling and what metadata you want returned in your test data with predictions\n5. Dichotomize categorical variables (for \u003ccode\u003eAutoXGBoostRegression()\u003c/code\u003e) and save the factor levels for scoring in a way that guarentees consistency across training, validation, and test data sets, utilizing the \u003ccode\u003eDummifyDT()\u003c/code\u003e function\n6. Save the final modeling column names for reference\n7. Handles the data conversion to the appropriate modeling type, such as CatBoost, H2O, and XGBoost\n8. Multi-armed bandit hyperparameter tuning using randomized probability matching, if you choose to grid tune\n9. Loop through the grid-tuning process, building N models\n10. Collect the evaluation metrics for each grid tune run\n11. Identify the best model of the set of models built in the grid tuning search\n12. Save the hyperparameters from the winning grid tuned model\n13. Build the final model based on the best model from the grid tuning model search (I remove each model after evaluation metrics are generated in the grid tune to avoid memory overflow)\n14. Back-transform your predictions based on the best transformation used earlier in the process\n15. Collect evaluation metrics based on performance on test data (based on back-transformed data)\n16. Store the final predictions with the associated test data and other columns you want included in that set\n17. Save your transformation metadata for recreating them in a scoring process\n18. Build out and save an Evaluation Calibration Line Plot and Evaluation Calibration Box-Plot, using the \u003ccode\u003eEvalPlot()\u003c/code\u003e function\n19. Generate and save Variable Importance\n20. Generate and save Partital Dependence Calibration Line Plots and Partital Dependence Calibration Box-Plots, using the \u003ccode\u003eParDepPlots()\u003c/code\u003e function\n21. Return all the objects generated in a named list for immediate use and evaluation\n \n\u003c/p\u003e\n\u003c/details\u003e\n\n\u003cdetails\u003e\u003csummary\u003eCatBoost Example\u003c/summary\u003e\n\u003cp\u003e\n\n```r\n# Create some dummy correlated data\ndata \u003c- AutoQuant::FakeDataGenerator(\n  Correlation = 0.85,\n  N = 10000,\n  ID = 2,\n  ZIP = 0,\n  AddDate = FALSE,\n  Classification = FALSE,\n  MultiClass = FALSE)\n\n# Run function\nTestModel \u003c- AutoQuant::AutoCatBoostRegression(\n\n  # GPU or CPU and the number of available GPUs\n  TrainOnFull = FALSE,\n  task_type = 'GPU',\n  NumGPUs = 1,\n  DebugMode = FALSE,\n\n  # Metadata args\n  OutputSelection = c('Importances', 'EvalPlots', 'EvalMetrics', 'Score_TrainData'),\n  ModelID = 'Test_Model_1',\n  model_path = normalizePath('./'),\n  metadata_path = normalizePath('./'),\n  SaveModelObjects = FALSE,\n  SaveInfoToPDF = FALSE,\n  ReturnModelObjects = TRUE,\n\n  # Data args\n  data = data,\n  ValidationData = NULL,\n  TestData = NULL,\n  TargetColumnName = 'Adrian',\n  FeatureColNames = names(data)[!names(data) %in%\n    c('IDcol_1', 'IDcol_2','Adrian')],\n  PrimaryDateColumn = NULL,\n  WeightsColumnName = NULL,\n  IDcols = c('IDcol_1','IDcol_2'),\n  TransformNumericColumns = 'Adrian',\n  Methods = c('BoxCox', 'Asinh', 'Asin', 'Log',\n    'LogPlus1', 'Sqrt', 'Logit'),\n\n  # Model evaluation\n  eval_metric = 'RMSE',\n  eval_metric_value = 1.5,\n  loss_function = 'RMSE',\n  loss_function_value = 1.5,\n  MetricPeriods = 10L,\n  NumOfParDepPlots = ncol(data)-1L-2L,\n\n  # Grid tuning args\n  PassInGrid = NULL,\n  GridTune = FALSE,\n  MaxModelsInGrid = 30L,\n  MaxRunsWithoutNewWinner = 20L,\n  MaxRunMinutes = 60*60,\n  BaselineComparison = 'default',\n\n  # ML args\n  langevin = FALSE,\n  diffusion_temperature = 10000,\n  Trees = 1000,\n  Depth = 9,\n  L2_Leaf_Reg = NULL,\n  RandomStrength = 1,\n  BorderCount = 128,\n  LearningRate = NULL,\n  RSM = 1,\n  BootStrapType = NULL,\n  GrowPolicy = 'SymmetricTree',\n  model_size_reg = 0.5,\n  feature_border_type = 'GreedyLogSum',\n  sampling_unit = 'Object',\n  subsample = NULL,\n  score_function = 'Cosine',\n  min_data_in_leaf = 1)\n```\n \n\u003c/p\u003e\n\u003c/details\u003e\n\n\u003cdetails\u003e\u003csummary\u003eXGBoost Example\u003c/summary\u003e\n\u003cp\u003e\n\n```r\n# Create some dummy correlated data\ndata \u003c- AutoQuant::FakeDataGenerator(\n  Correlation = 0.85,\n  N = 1000,\n  ID = 2,\n  ZIP = 0,\n  AddDate = FALSE,\n  Classification = FALSE,\n  MultiClass = FALSE)\n\n# Run function\nTestModel \u003c- AutoQuant::AutoXGBoostRegression(\n  \n  # GPU or CPU\n  TreeMethod = 'hist',\n  NThreads = parallel::detectCores(),\n  LossFunction = 'reg:squarederror',\n  \n  # Metadata args\n  OutputSelection = c('Importances', 'EvalPlots', 'EvalMetrics', 'Score_TrainData'),\n  model_path = normalizePath(\"./\"),\n  metadata_path = NULL,\n  ModelID = \"Test_Model_1\",\n  EncodingMethod = \"binary\",\n  ReturnFactorLevels = TRUE,\n  ReturnModelObjects = TRUE,\n  SaveModelObjects = FALSE,\n  SaveInfoToPDF = FALSE,\n  DebugMode = FALSE,\n  \n  # Data args\n  data = data,\n  TrainOnFull = FALSE,\n  ValidationData = NULL,\n  TestData = NULL,\n  TargetColumnName = \"Adrian\",\n  FeatureColNames = names(data)[!names(data) %in% c('IDcol_1','IDcol_2','Adrian')],\n  PrimaryDateColumn = NULL,\n  WeightsColumnName = NULL,\n  IDcols = c('IDcol_1','IDcol_2'),\n  TransformNumericColumns = 'Adrian',\n  Methods = c('Asinh','Asin','Log','LogPlus1','Sqrt','Logit'),\n  \n  # Model evaluation args\n  eval_metric = 'rmse',\n  NumOfParDepPlots = 3L,\n  \n  # Grid tuning args\n  PassInGrid = NULL,\n  GridTune = FALSE,\n  grid_eval_metric = 'r2',\n  BaselineComparison = 'default',\n  MaxModelsInGrid = 10L,\n  MaxRunsWithoutNewWinner = 20L,\n  MaxRunMinutes = 24L*60L,\n  Verbose = 1L,\n  \n  # ML args\n  Trees = 50L,\n  eta = 0.05,\n  max_depth = 4L,\n  min_child_weight = 1.0,\n  subsample = 0.55,\n  colsample_bytree = 0.55)\n```\n\n\u003c/p\u003e\n\u003c/details\u003e\n\n\u003cdetails\u003e\u003csummary\u003eLightGBM Example\u003c/summary\u003e\n\u003cp\u003e\n\n```r\n# Create some dummy correlated data\ndata \u003c- AutoQuant::FakeDataGenerator(\n  Correlation = 0.85,\n  N = 1000,\n  ID = 2,\n  ZIP = 0,\n  AddDate = FALSE,\n  Classification = FALSE,\n  MultiClass = FALSE)\n\n# Run function\nTestModel \u003c- AutoQuant::AutoLightGBMRegression(\n\n  # Metadata args\n  OutputSelection = c('Importances','EvalPlots','EvalMetrics','Score_TrainData'),\n  model_path = normalizePath('./'),\n  metadata_path = NULL,\n  ModelID = 'Test_Model_1',\n  NumOfParDepPlots = 3L,\n  EncodingMethod = 'credibility',\n  ReturnFactorLevels = TRUE,\n  ReturnModelObjects = TRUE,\n  SaveModelObjects = FALSE,\n  SaveInfoToPDF = FALSE,\n  DebugMode = FALSE,\n\n  # Data args\n  data = data,\n  TrainOnFull = FALSE,\n  ValidationData = NULL,\n  TestData = NULL,\n  TargetColumnName = 'Adrian',\n  FeatureColNames = names(data)[!names(data) %in% c('IDcol_1', 'IDcol_2','Adrian')],\n  PrimaryDateColumn = NULL,\n  WeightsColumnName = NULL,\n  IDcols = c('IDcol_1','IDcol_2'),\n  TransformNumericColumns = NULL,\n  Methods = c('Asinh','Asin','Log','LogPlus1','Sqrt','Logit'),\n\n  # Grid parameters\n  GridTune = FALSE,\n  grid_eval_metric = 'r2',\n  BaselineComparison = 'default',\n  MaxModelsInGrid = 10L,\n  MaxRunsWithoutNewWinner = 20L,\n  MaxRunMinutes = 24L*60L,\n  PassInGrid = NULL,\n\n  # Core parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#core-parameters\n  input_model = NULL, # continue training a model that is stored to file\n  task = 'train',\n  device_type = 'CPU',\n  NThreads = parallel::detectCores() / 2,\n  objective = 'regression',\n  metric = 'rmse',\n  boosting = 'gbdt',\n  LinearTree = FALSE,\n  Trees = 50L,\n  eta = NULL,\n  num_leaves = 31,\n  deterministic = TRUE,\n\n  # Learning Parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#learning-control-parameters\n  force_col_wise = FALSE,\n  force_row_wise = FALSE,\n  max_depth = NULL,\n  min_data_in_leaf = 20,\n  min_sum_hessian_in_leaf = 0.001,\n  bagging_freq = 0,\n  bagging_fraction = 1.0,\n  feature_fraction = 1.0,\n  feature_fraction_bynode = 1.0,\n  extra_trees = FALSE,\n  early_stopping_round = 10,\n  first_metric_only = TRUE,\n  max_delta_step = 0.0,\n  lambda_l1 = 0.0,\n  lambda_l2 = 0.0,\n  linear_lambda = 0.0,\n  min_gain_to_split = 0,\n  drop_rate_dart = 0.10,\n  max_drop_dart = 50,\n  skip_drop_dart = 0.50,\n  uniform_drop_dart = FALSE,\n  top_rate_goss = FALSE,\n  other_rate_goss = FALSE,\n  monotone_constraints = NULL,\n  monotone_constraints_method = 'advanced',\n  monotone_penalty = 0.0,\n  forcedsplits_filename = NULL, # use for AutoStack option; .json file\n  refit_decay_rate = 0.90,\n  path_smooth = 0.0,\n\n  # IO Dataset Parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#io-parameters\n  max_bin = 255,\n  min_data_in_bin = 3,\n  data_random_seed = 1,\n  is_enable_sparse = TRUE,\n  enable_bundle = TRUE,\n  use_missing = TRUE,\n  zero_as_missing = FALSE,\n  two_round = FALSE,\n\n  # Convert Parameters\n  convert_model = NULL,\n  convert_model_language = 'cpp',\n\n  # Objective Parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#objective-parameters\n  boost_from_average = TRUE,\n  alpha = 0.90,\n  fair_c = 1.0,\n  poisson_max_delta_step = 0.70,\n  tweedie_variance_power = 1.5,\n  lambdarank_truncation_level = 30,\n\n  # Metric Parameters (metric is in Core)\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#metric-parameters\n  is_provide_training_metric = TRUE,\n  eval_at = c(1,2,3,4,5),\n\n  # Network Parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#network-parameters\n  num_machines = 1,\n\n  # GPU Parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#gpu-parameters\n  gpu_platform_id = -1,\n  gpu_device_id = -1,\n  gpu_use_dp = TRUE,\n  num_gpu = 1)\n```\n\n\u003c/p\u003e\n\u003c/details\u003e \n\n\u003cdetails\u003e\u003csummary\u003eH2O-GBM Example\u003c/summary\u003e\n\u003cp\u003e\n\n```r\n# Create some dummy correlated data\ndata \u003c- AutoQuant::FakeDataGenerator(\n  Correlation = 0.85,\n  N = 1000,\n  ID = 2,\n  ZIP = 0,\n  AddDate = FALSE,\n  Classification = FALSE,\n  MultiClass = FALSE)\n\n# Run function\nTestModel \u003c- AutoQuant::AutoH2oGBMRegression(\n  \n  # Compute management\n  MaxMem = {gc();paste0(as.character(floor(as.numeric(system(\"awk '/MemFree/ {print $2}' /proc/meminfo\", intern=TRUE)) / 1000000)),\"G\")},\n  NThreads = max(1, parallel::detectCores()-2),\n  H2OShutdown = TRUE,\n  H2OStartUp = TRUE,\n  IfSaveModel = \"mojo\",\n  \n  # Model evaluation\n  NumOfParDepPlots = 3,\n  \n  # Metadata arguments:\n  model_path = normalizePath(\"./\"),\n  metadata_path = file.path(normalizePath(\"./\")),\n  ModelID = \"FirstModel\",\n  ReturnModelObjects = TRUE,\n  SaveModelObjects = FALSE,\n  SaveInfoToPDF = FALSE,\n  \n  # Data arguments\n  data = data,\n  TrainOnFull = FALSE,\n  ValidationData = NULL,\n  TestData = NULL,\n  TargetColumnName = 'Adrian',\n  FeatureColNames = names(data)[!names(data) %in% c('IDcol_1','IDcol_2','Adrian')],\n  WeightsColumn = NULL,\n  TransformNumericColumns = NULL,\n  Methods = c('Asinh','Asin','Log','LogPlus1','Sqrt','Logit'),\n  \n  # ML grid tuning args\n  GridTune = FALSE,\n  GridStrategy = \"Cartesian\",\n  MaxRuntimeSecs = 60*60*24,\n  StoppingRounds = 10,\n  MaxModelsInGrid = 2,\n  \n  # Model args\n  Trees = 50,\n  LearnRate = 0.10,\n  LearnRateAnnealing = 1,\n  eval_metric = \"RMSE\",\n  Alpha = NULL,\n  Distribution = \"poisson\",\n  MaxDepth = 20,\n  SampleRate = 0.632,\n  ColSampleRate = 1,\n  ColSampleRatePerTree = 1,\n  ColSampleRatePerTreeLevel  = 1,\n  MinRows = 1,\n  NBins = 20,\n  NBinsCats = 1024,\n  NBinsTopLevel = 1024,\n  HistogramType = \"AUTO\",\n  CategoricalEncoding = \"AUTO\")\n```\n \n\u003c/p\u003e\n\u003c/details\u003e\n\n\u003cdetails\u003e\u003csummary\u003eH2O-DRF Example\u003c/summary\u003e\n\u003cp\u003e\n \n```r\n# Create some dummy correlated data\ndata \u003c- AutoQuant::FakeDataGenerator(\n  Correlation = 0.85,\n  N = 1000,\n  ID = 2,\n  ZIP = 0,\n  AddDate = FALSE,\n  Classification = FALSE,\n  MultiClass = FALSE)\n\n# Run function\nTestModel \u003c- AutoQuant::AutoH2oDRFRegression(\n  \n  # Compute management\n  MaxMem = {gc();paste0(as.character(floor(as.numeric(system(\"awk '/MemFree/ {print $2}' /proc/meminfo\", intern=TRUE)) / 1000000)),\"G\")},\n  NThreads = max(1L, parallel::detectCores() - 2L),\n  H2OShutdown = TRUE,\n  H2OStartUp = TRUE,\n  IfSaveModel = \"mojo\",\n  \n  # Model evaluation:\n  eval_metric = \"RMSE\",\n  NumOfParDepPlots = 3,\n  \n  # Metadata arguments:\n  model_path = normalizePath(\"./\"),\n  metadata_path = NULL,\n  ModelID = \"FirstModel\",\n  ReturnModelObjects = TRUE,\n  SaveModelObjects = FALSE,\n  SaveInfoToPDF = FALSE,\n  \n  # Data Args\n  data = data,\n  TrainOnFull = FALSE,\n  ValidationData = NULL,\n  TestData = NULL,\n  TargetColumnName = \"Adrian\",\n  FeatureColNames = names(data)[!names(data) %in% c(\"IDcol_1\", \"IDcol_2\",\"Adrian\")],\n  WeightsColumn = NULL,\n  TransformNumericColumns = NULL,\n  Methods = c(\"Asinh\", \"Asin\", \"Log\", \"LogPlus1\", \"Sqrt\", \"Logit\"),\n  \n  # Grid Tuning Args\n  GridStrategy = \"Cartesian\",\n  GridTune = FALSE,\n  MaxModelsInGrid = 10,\n  MaxRuntimeSecs = 60*60*24,\n  StoppingRounds = 10,\n  \n  # ML Args\n  Trees = 50,\n  MaxDepth = 20,\n  SampleRate = 0.632,\n  MTries = -1,\n  ColSampleRatePerTree = 1,\n  ColSampleRatePerTreeLevel = 1,\n  MinRows = 1,\n  NBins = 20,\n  NBinsCats = 1024,\n  NBinsTopLevel = 1024,\n  HistogramType = \"AUTO\",\n  CategoricalEncoding = \"AUTO\")\n```\n \n\u003c/p\u003e\n\u003c/details\u003e\n\n\u003cdetails\u003e\u003csummary\u003eH2O-GLM Example\u003c/summary\u003e\n\u003cp\u003e\n \n```r\n# Create some dummy correlated data\ndata \u003c- AutoQuant::FakeDataGenerator(\n  Correlation = 0.85,\n  N = 1000,\n  ID = 2,\n  ZIP = 0,\n  AddDate = FALSE,\n  Classification = FALSE,\n  MultiClass = FALSE)\n\n# Run function\nTestModel \u003c- AutoQuant::AutoH2oGLMRegression(\n  \n  # Compute management\n  MaxMem = {gc();paste0(as.character(floor(as.numeric(system(\"awk '/MemFree/ {print $2}' /proc/meminfo\", intern=TRUE)) / 1000000)),\"G\")},\n  NThreads = max(1, parallel::detectCores()-2),\n  H2OShutdown = TRUE,\n  H2OStartUp = TRUE,\n  IfSaveModel = \"mojo\",\n  \n  # Model evaluation:\n  eval_metric = \"RMSE\",\n  NumOfParDepPlots = 3,\n  \n  # Metadata arguments:\n  model_path = NULL,\n  metadata_path = NULL,\n  ModelID = \"FirstModel\",\n  ReturnModelObjects = TRUE,\n  SaveModelObjects = FALSE,\n  SaveInfoToPDF = FALSE,\n  \n  # Data arguments:\n  data = data,\n  TrainOnFull = FALSE,\n  ValidationData = NULL,\n  TestData = NULL,\n  TargetColumnName = \"Adrian\",\n  FeatureColNames = names(data)[!names(data) %in% c(\"IDcol_1\", \"IDcol_2\",\"Adrian\")],\n  RandomColNumbers = NULL,\n  InteractionColNumbers = NULL,\n  WeightsColumn = NULL,\n  TransformNumericColumns = NULL,\n  Methods = c(\"Asinh\", \"Asin\", \"Log\", \"LogPlus1\", \"Sqrt\", \"Logit\"),\n  \n  # Model args\n  GridTune = FALSE,\n  GridStrategy = \"Cartesian\",\n  StoppingRounds = 10,\n  MaxRunTimeSecs = 3600 * 24 * 7,\n  MaxModelsInGrid = 10,\n  Distribution = \"gaussian\",\n  Link = \"identity\",\n  TweedieLinkPower = NULL,\n  TweedieVariancePower = NULL,\n  RandomDistribution = NULL,\n  RandomLink = NULL,\n  Solver = \"AUTO\",\n  Alpha = NULL,\n  Lambda = NULL,\n  LambdaSearch = FALSE,\n  NLambdas = -1,\n  Standardize = TRUE,\n  RemoveCollinearColumns = FALSE,\n  InterceptInclude = TRUE,\n  NonNegativeCoefficients = FALSE)\n```\n \n\u003c/p\u003e\n\u003c/details\u003e\n\n\u003cdetails\u003e\u003csummary\u003eH2O-AutoML Example\u003c/summary\u003e\n\u003cp\u003e\n \n```r\n# Create some dummy correlated data with numeric and categorical features\ndata \u003c- AutoQuant::FakeDataGenerator(\n  Correlation = 0.85,\n  N = 1000,\n  ID = 2,\n  ZIP = 0,\n  AddDate = FALSE,\n  Classification = FALSE,\n  MultiClass = FALSE)\n\n# Run function\nTestModel \u003c- AutoQuant::AutoH2oMLRegression(\n\n  # Compute management\n  MaxMem = \"32G\",\n  NThreads = max(1, parallel::detectCores()-2),\n  H2OShutdown = TRUE,\n  IfSaveModel = \"mojo\",\n\n  # Model evaluation\n  eval_metric = \"RMSE\",\n  NumOfParDepPlots = 3,\n\n  # Metadata arguments\n  model_path = NULL,\n  metadata_path = NULL,\n  ModelID = \"FirstModel\",\n  ReturnModelObjects = TRUE,\n  SaveModelObjects = FALSE,\n\n  # Data arguments\n  TrainOnFull = FALSE,\n  ValidationData = NULL,\n  TestData = NULL,\n  TargetColumnName = \"Adrian\",\n  FeatureColNames = names(data)[!names(data) %in% c(\"IDcol_1\", \"IDcol_2\",\"Adrian\")],\n  TransformNumericColumns = NULL,\n  Methods = c(\"Asinh\", \"Asin\", \"Log\", \"LogPlus1\", \"Logit\"),\n\n  # Model args\n  GridTune = FALSE,\n  ExcludeAlgos = NULL,\n  Trees = 50,\n  MaxModelsInGrid = 10)\n```\n\n\u003c/p\u003e\n\u003c/details\u003e \n\n\u003cdetails\u003e\u003csummary\u003eH2O-GAM Example\u003c/summary\u003e\n\u003cp\u003e\n \n```r\n# Create some dummy correlated data\ndata \u003c- AutoQuant::FakeDataGenerator(\n  Correlation = 0.85,\n  N = 1000,\n  ID = 2,\n  ZIP = 0,\n  AddDate = FALSE,\n  Classification = FALSE,\n  MultiClass = FALSE)\n\n# Define GAM Columns to use - up to 9 are allowed\nGamCols \u003c- names(which(unlist(lapply(data, is.numeric))))\nGamCols \u003c- GamCols[!GamCols %in% c(\"Adrian\",\"IDcol_1\",\"IDcol_2\")]\nGamCols \u003c- GamCols[1L:(min(9L,length(GamCols)))]\n\n# Run function\nTestModel \u003c- AutoQuant::AutoH2oGAMRegression(\n  \n  # Compute management\n  MaxMem = {gc();paste0(as.character(floor(as.numeric(system(\"awk '/MemFree/ {print $2}' /proc/meminfo\", intern=TRUE)) / 1000000)),\"G\")},\n  NThreads = max(1, parallel::detectCores()-2),\n  H2OShutdown = TRUE,\n  H2OStartUp = TRUE,\n  IfSaveModel = \"mojo\",\n  \n  # Model evaluation:\n  eval_metric = \"RMSE\",\n  NumOfParDepPlots = 3,\n  \n  # Metadata arguments:\n  model_path = NULL,\n  metadata_path = NULL,\n  ModelID = \"FirstModel\",\n  ReturnModelObjects = TRUE,\n  SaveModelObjects = FALSE,\n  SaveInfoToPDF = FALSE,\n  \n  # Data arguments:\n  data = data,\n  TrainOnFull = FALSE,\n  ValidationData = NULL,\n  TestData = NULL,\n  TargetColumnName = \"Adrian\",\n  FeatureColNames = names(data)[!names(data) %in% c(\"IDcol_1\", \"IDcol_2\",\"Adrian\")],\n  InteractionColNumbers = NULL,\n  WeightsColumn = NULL,\n  GamColNames = GamCols,\n  TransformNumericColumns = NULL,\n  Methods = c(\"Asinh\", \"Asin\", \"Log\", \"LogPlus1\", \"Sqrt\", \"Logit\"),\n  \n  # Model args\n  num_knots = NULL,\n  keep_gam_cols = TRUE,\n  GridTune = FALSE,\n  GridStrategy = \"Cartesian\",\n  StoppingRounds = 10,\n  MaxRunTimeSecs = 3600 * 24 * 7,\n  MaxModelsInGrid = 10,\n  Distribution = \"gaussian\",\n  Link = \"Family_Default\",\n  TweedieLinkPower = NULL,\n  TweedieVariancePower = NULL,\n  Solver = \"AUTO\",\n  Alpha = NULL,\n  Lambda = NULL,\n  LambdaSearch = FALSE,\n  NLambdas = -1,\n  Standardize = TRUE,\n  RemoveCollinearColumns = FALSE,\n  InterceptInclude = TRUE,\n  NonNegativeCoefficients = FALSE)\n```\n \n\u003c/p\u003e\n\u003c/details\u003e \n\n\u003c/p\u003e\n\u003c/details\u003e\n\n### Binary Classification\n\n\u003cdetails\u003e\u003csummary\u003eclick to expand\u003c/summary\u003e\n\u003cp\u003e\n\n\u003cdetails\u003e\u003csummary\u003eClassification Description\u003c/summary\u003e\n\u003cp\u003e\n  \nThe Auto_Classifier() models handle a multitude of tasks. In order:\n1. Convert your data to data.table format for faster processing\n2. Create train, validation, and test data if you didn't supply those directly to the function\n3. Consoldate columns that are used for modeling and what is to be kept for data returned\n4. Dichotomize categorical variables (for AutoXGBoostRegression) and save the factor levels for scoring in a way that guarentees consistency across training, validation, and test data sets\n5. Saves the final column names for modeling to a csv for later reference\n6. Handles the data conversion to the appropriate type, based on model type (CatBoost, H2O, and XGBoost)\n7. Multi-armed bandit hyperparameter tuning using randomized probability matching, if you choose to grid tune\n8. Build the grid tuned models\n9. Collect the evaluation metrics for each grid tune run\n10. Identify the best model of the set of models built in the grid tuning setup\n11. Save the hyperparameters from the winning grid tuned model\n12. Build the final model based on the best model from the grid tuning model search\n13. Collect evaluation metrics based on performance on test data\n14. Store the final predictions with the associated test data and other columns you want included in that set\n15. Build out and save an Evaluation Calibration Line Plot\n16. Build out and save an ROC plot with the top 5 models used in grid-tuning (includes the winning model)\n17. Generate and save Variable Importance data\n18. Generate and save Partital Dependence Calibration Line Plots\n19. Return all the objects generated in a named list for immediate use\n\n\u003c/p\u003e\n\u003c/details\u003e\n\n\u003cdetails\u003e\u003csummary\u003eCatBoost Example\u003c/summary\u003e\n\u003cp\u003e\n\n```r\n# Create some dummy correlated data\ndata \u003c- AutoQuant::FakeDataGenerator(\n  Correlation = 0.85,\n  N = 10000,\n  ID = 2,\n  ZIP = 0,\n  AddDate = FALSE,\n  Classification = TRUE,\n  MultiClass = FALSE)\n\n# Run function\nTestModel \u003c- AutoQuant::AutoCatBoostClassifier(\n\n  # GPU or CPU and the number of available GPUs\n  task_type = 'GPU',\n  NumGPUs = 1,\n  TrainOnFull = FALSE,\n  DebugMode = FALSE,\n\n  # Metadata args\n  OutputSelection = c('Score_TrainData', 'Importance', 'EvalPlots', 'Metrics', 'PDF'),\n  ModelID = 'Test_Model_1',\n  model_path = normalizePath('./'),\n  metadata_path = normalizePath('./'),\n  SaveModelObjects = FALSE,\n  ReturnModelObjects = TRUE,\n  SaveInfoToPDF = FALSE,\n\n  # Data args\n  data = data,\n  ValidationData = NULL,\n  TestData = NULL,\n  TargetColumnName = 'Adrian',\n  FeatureColNames = names(data)[!names(data) %in%\n     c('IDcol_1','IDcol_2','Adrian')],\n  PrimaryDateColumn = NULL,\n  WeightsColumnName = NULL,\n  IDcols = c('IDcol_1','IDcol_2'),\n\n  # Evaluation args\n  ClassWeights = c(1L,1L),\n  CostMatrixWeights = c(1,0,0,1),\n  EvalMetric = 'AUC',\n  grid_eval_metric = 'MCC',\n  LossFunction = 'Logloss',\n  MetricPeriods = 10L,\n  NumOfParDepPlots = ncol(data)-1L-2L,\n\n  # Grid tuning args\n  PassInGrid = NULL,\n  GridTune = FALSE,\n  MaxModelsInGrid = 30L,\n  MaxRunsWithoutNewWinner = 20L,\n  MaxRunMinutes = 24L*60L,\n  BaselineComparison = 'default',\n\n  # ML args\n  Trees = 1000,\n  Depth = 9,\n  LearningRate = NULL,\n  L2_Leaf_Reg = NULL,\n  model_size_reg = 0.5,\n  langevin = FALSE,\n  diffusion_temperature = 10000,\n  RandomStrength = 1,\n  BorderCount = 128,\n  RSM = 1,\n  BootStrapType = 'Bayesian',\n  GrowPolicy = 'SymmetricTree',\n  feature_border_type = 'GreedyLogSum',\n  sampling_unit = 'Object',\n  subsample = NULL,\n  score_function = 'Cosine',\n  min_data_in_leaf = 1)\n```\n\n\u003c/p\u003e\n\u003c/details\u003e\n\n\u003cdetails\u003e\u003csummary\u003eXGBoost Example\u003c/summary\u003e\n\u003cp\u003e\n \n```r\n# Create some dummy correlated data\ndata \u003c- AutoQuant::FakeDataGenerator(\n  Correlation = 0.85,\n  N = 1000L,\n  ID = 2L,\n  ZIP = 0L,\n  AddDate = FALSE,\n  Classification = TRUE,\n  MultiClass = FALSE)\n\n# Run function\nTestModel \u003c- AutoQuant::AutoXGBoostClassifier(\n\n  # GPU or CPU\n  TreeMethod = \"hist\",\n  NThreads = parallel::detectCores(),\n\n  # Metadata args\n  OutputSelection = c(\"Importances\", \"EvalPlots\", \"EvalMetrics\", \"PDFs\", \"Score_TrainData\"),\n  model_path = normalizePath(\"./\"),\n  metadata_path = NULL,\n  ModelID = \"Test_Model_1\",\n  EncodingMethod = \"binary\",\n  ReturnFactorLevels = TRUE,\n  ReturnModelObjects = TRUE,\n  SaveModelObjects = FALSE,\n  SaveInfoToPDF = FALSE,\n\n  # Data args\n  data = data,\n  TrainOnFull = FALSE,\n  ValidationData = NULL,\n  TestData = NULL,\n  TargetColumnName = \"Adrian\",\n  FeatureColNames = names(data)[!names(data) %in%\n    c(\"IDcol_1\", \"IDcol_2\",\"Adrian\")],\n  WeightsColumnName = NULL,\n  IDcols = c(\"IDcol_1\",\"IDcol_2\"),\n\n  # Model evaluation\n  LossFunction = 'reg:logistic',\n  CostMatrixWeights = c(1,0,0,1),\n  eval_metric = \"auc\",\n  grid_eval_metric = \"MCC\",\n  NumOfParDepPlots = 3L,\n\n  # Grid tuning args\n  PassInGrid = NULL,\n  GridTune = FALSE,\n  BaselineComparison = \"default\",\n  MaxModelsInGrid = 10L,\n  MaxRunsWithoutNewWinner = 20L,\n  MaxRunMinutes = 24L*60L,\n  Verbose = 1L,\n\n  # ML args\n  Trees = 500L,\n  eta = 0.30,\n  max_depth = 9L,\n  min_child_weight = 1.0,\n  subsample = 1,\n  colsample_bytree = 1,\n  DebugMode = FALSE)\n```\n\n\u003c/p\u003e\n\u003c/details\u003e \n\n\u003cdetails\u003e\u003csummary\u003eLightGBM Example\u003c/summary\u003e\n\u003cp\u003e\n \n```r\n# Create some dummy correlated data\ndata \u003c- AutoQuant::FakeDataGenerator(\n  Correlation = 0.85,\n  N = 1000,\n  ID = 2,\n  ZIP = 0,\n  AddDate = FALSE,\n  Classification = FALSE,\n  MultiClass = FALSE)\n\n# Run function\nTestModel \u003c- AutoQuant::AutoLightGBMClassifier(\n\n  # Metadata args\n  OutputSelection = c(\"Importances\",\"EvalPlots\",\"EvalMetrics\",\"Score_TrainData\"),\n  model_path = normalizePath(\"./\"),\n  metadata_path = NULL,\n  ModelID = \"Test_Model_1\",\n  NumOfParDepPlots = 3L,\n  EncodingMethod = \"credibility\",\n  ReturnFactorLevels = TRUE,\n  ReturnModelObjects = TRUE,\n  SaveModelObjects = FALSE,\n  SaveInfoToPDF = FALSE,\n  DebugMode = FALSE,\n\n  # Data args\n  data = data,\n  TrainOnFull = FALSE,\n  ValidationData = NULL,\n  TestData = NULL,\n  TargetColumnName = \"Adrian\",\n  FeatureColNames = names(data)[!names(data) %in% c(\"IDcol_1\", \"IDcol_2\",\"Adrian\")],\n  PrimaryDateColumn = NULL,\n  WeightsColumnName = NULL,\n  IDcols = c(\"IDcol_1\",\"IDcol_2\"),\n\n  # Grid parameters\n  GridTune = FALSE,\n  grid_eval_metric = 'Utility',\n  BaselineComparison = 'default',\n  MaxModelsInGrid = 10L,\n  MaxRunsWithoutNewWinner = 20L,\n  MaxRunMinutes = 24L*60L,\n  PassInGrid = NULL,\n\n  # Core parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#core-parameters\n  input_model = NULL, # continue training a model that is stored to file\n  task = \"train\",\n  device_type = 'CPU',\n  NThreads = parallel::detectCores() / 2,\n  objective = 'binary',\n  metric = 'binary_logloss',\n  boosting = 'gbdt',\n  LinearTree = FALSE,\n  Trees = 50L,\n  eta = NULL,\n  num_leaves = 31,\n  deterministic = TRUE,\n\n  # Learning Parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#learning-control-parameters\n  force_col_wise = FALSE,\n  force_row_wise = FALSE,\n  max_depth = NULL,\n  min_data_in_leaf = 20,\n  min_sum_hessian_in_leaf = 0.001,\n  bagging_freq = 0,\n  bagging_fraction = 1.0,\n  feature_fraction = 1.0,\n  feature_fraction_bynode = 1.0,\n  extra_trees = FALSE,\n  early_stopping_round = 10,\n  first_metric_only = TRUE,\n  max_delta_step = 0.0,\n  lambda_l1 = 0.0,\n  lambda_l2 = 0.0,\n  linear_lambda = 0.0,\n  min_gain_to_split = 0,\n  drop_rate_dart = 0.10,\n  max_drop_dart = 50,\n  skip_drop_dart = 0.50,\n  uniform_drop_dart = FALSE,\n  top_rate_goss = FALSE,\n  other_rate_goss = FALSE,\n  monotone_constraints = NULL,\n  monotone_constraints_method = \"advanced\",\n  monotone_penalty = 0.0,\n  forcedsplits_filename = NULL, # use for AutoStack option; .json file\n  refit_decay_rate = 0.90,\n  path_smooth = 0.0,\n\n  # IO Dataset Parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#io-parameters\n  max_bin = 255,\n  min_data_in_bin = 3,\n  data_random_seed = 1,\n  is_enable_sparse = TRUE,\n  enable_bundle = TRUE,\n  use_missing = TRUE,\n  zero_as_missing = FALSE,\n  two_round = FALSE,\n\n  # Convert Parameters\n  convert_model = NULL,\n  convert_model_language = \"cpp\",\n\n  # Objective Parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#objective-parameters\n  boost_from_average = TRUE,\n  is_unbalance = FALSE,\n  scale_pos_weight = 1.0,\n\n  # Metric Parameters (metric is in Core)\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#metric-parameters\n  is_provide_training_metric = TRUE,\n  eval_at = c(1,2,3,4,5),\n\n  # Network Parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#network-parameters\n  num_machines = 1,\n\n  # GPU Parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#gpu-parameters\n  gpu_platform_id = -1,\n  gpu_device_id = -1,\n  gpu_use_dp = TRUE,\n  num_gpu = 1)\n```\n\n\u003c/p\u003e\n\u003c/details\u003e \n\n\u003cdetails\u003e\u003csummary\u003eH2O-GBM Example\u003c/summary\u003e\n\u003cp\u003e\n\n```r\n# Create some dummy correlated data\ndata \u003c- AutoQuant::FakeDataGenerator(\n  Correlation = 0.85,\n  N = 1000L,\n  ID = 2L,\n  ZIP = 0L,\n  AddDate = FALSE,\n  Classification = TRUE,\n  MultiClass = FALSE)\n\nTestModel \u003c- AutoQuant::AutoH2oGBMClassifier(\n  \n  # Compute management\n  MaxMem = {gc();paste0(as.character(floor(as.numeric(system(\"awk '/MemFree/ {print $2}' /proc/meminfo\", intern=TRUE)) / 1000000)),\"G\")},\n  NThreads = max(1, parallel::detectCores()-2),\n  H2OShutdown = TRUE,\n  H2OStartUp = TRUE,\n  IfSaveModel = \"mojo\",\n  \n  # Model evaluation\n  NumOfParDepPlots = 3,\n  \n  # Metadata arguments:\n  model_path = normalizePath(\"./\"),\n  metadata_path = file.path(normalizePath(\"./\")),\n  ModelID = \"FirstModel\",\n  ReturnModelObjects = TRUE,\n  SaveModelObjects = FALSE,\n  SaveInfoToPDF = FALSE,\n  \n  # Data arguments\n  data = data,\n  TrainOnFull = FALSE,\n  ValidationData = NULL,\n  TestData = NULL,\n  TargetColumnName = \"Adrian\",\n  FeatureColNames = names(data)[!names(data) %in% c(\"IDcol_1\", \"IDcol_2\",\"Adrian\")],\n  WeightsColumn = NULL,\n  \n  # ML grid tuning args\n  GridTune = FALSE,\n  GridStrategy = \"Cartesian\",\n  MaxRuntimeSecs = 60*60*24,\n  StoppingRounds = 10,\n  MaxModelsInGrid = 2,\n  \n  # Model args\n  Trees = 50,\n  LearnRate = 0.10,\n  LearnRateAnnealing = 1,\n  eval_metric = \"auc\",\n  Distribution = \"bernoulli\",\n  MaxDepth = 20,\n  SampleRate = 0.632,\n  ColSampleRate = 1,\n  ColSampleRatePerTree = 1,\n  ColSampleRatePerTreeLevel  = 1,\n  MinRows = 1,\n  NBins = 20,\n  NBinsCats = 1024,\n  NBinsTopLevel = 1024,\n  HistogramType = \"AUTO\",\n  CategoricalEncoding = \"AUTO\")\n```\n\n\u003c/p\u003e\n\u003c/details\u003e \n\n\u003cdetails\u003e\u003csummary\u003eH2O-DRF Example\u003c/summary\u003e\n\u003cp\u003e\n \n```r\n# Create some dummy correlated data\ndata \u003c- AutoQuant::FakeDataGenerator(\n  Correlation = 0.85,\n  N = 1000L,\n  ID = 2L,\n  ZIP = 0L,\n  AddDate = FALSE,\n  Classification = TRUE,\n  MultiClass = FALSE)\n\nTestModel \u003c- AutoQuant::AutoH2oDRFClassifier(\n  \n  # Compute management\n  MaxMem = {gc();paste0(as.character(floor(as.numeric(system(\"awk '/MemFree/ {print $2}' /proc/meminfo\", intern=TRUE)) / 1000000)),\"G\")},\n  NThreads = max(1L, parallel::detectCores() - 2L),\n  IfSaveModel = \"mojo\",\n  H2OShutdown = FALSE,\n  H2OStartUp = TRUE,\n  \n  # Metadata arguments:\n  eval_metric = \"auc\",\n  NumOfParDepPlots = 3L,\n  \n  # Data arguments:\n  model_path = normalizePath(\"./\"),\n  metadata_path = NULL,\n  ModelID = \"FirstModel\",\n  ReturnModelObjects = TRUE,\n  SaveModelObjects = FALSE,\n  SaveInfoToPDF = FALSE,\n  \n  # Model evaluation:\n  data,\n  TrainOnFull = FALSE,\n  ValidationData = NULL,\n  TestData = NULL,\n  TargetColumnName = \"Adrian\",\n  FeatureColNames = names(data)[!names(data) %in% c(\"IDcol_1\", \"IDcol_2\", \"Adrian\")],\n  WeightsColumn = NULL,\n  \n  # Grid Tuning Args\n  GridStrategy = \"Cartesian\",\n  GridTune = FALSE,\n  MaxModelsInGrid = 10,\n  MaxRuntimeSecs = 60*60*24,\n  StoppingRounds = 10,\n  \n  # Model args\n  Trees = 50L,\n  MaxDepth = 20,\n  SampleRate = 0.632,\n  MTries = -1,\n  ColSampleRatePerTree = 1,\n  ColSampleRatePerTreeLevel = 1,\n  MinRows = 1,\n  NBins = 20,\n  NBinsCats = 1024,\n  NBinsTopLevel = 1024,\n  HistogramType = \"AUTO\",\n  CategoricalEncoding = \"AUTO\")\n```\n \n\u003c/p\u003e\n\u003c/details\u003e \n\n\u003cdetails\u003e\u003csummary\u003eH2O-GLM Example\u003c/summary\u003e\n\u003cp\u003e\n \n```r\n# Create some dummy correlated data with numeric and categorical features\ndata \u003c- AutoQuant::FakeDataGenerator(\n  Correlation = 0.85,\n  N = 1000L,\n  ID = 2L,\n  ZIP = 0L,\n  AddDate = FALSE,\n  Classification = TRUE,\n  MultiClass = FALSE)\n\n# Run function\nTestModel \u003c- AutoQuant::AutoH2oGLMClassifier(\n  \n  # Compute management\n  MaxMem = {gc();paste0(as.character(floor(as.numeric(system(\"awk '/MemFree/ {print $2}' /proc/meminfo\", intern=TRUE)) / 1000000)),\"G\")},\n  NThreads = max(1, parallel::detectCores()-2),\n  H2OShutdown = TRUE,\n  H2OStartUp = TRUE,\n  IfSaveModel = \"mojo\",\n  \n  # Model evaluation args\n  eval_metric = \"auc\",\n  NumOfParDepPlots = 3,\n  \n  # Metadata args\n  model_path = NULL,\n  metadata_path = NULL,\n  ModelID = \"FirstModel\",\n  ReturnModelObjects = TRUE,\n  SaveModelObjects = FALSE,\n  SaveInfoToPDF = FALSE,\n  \n  # Data args\n  data = data,\n  TrainOnFull = FALSE,\n  ValidationData = NULL,\n  TestData = NULL,\n  TargetColumnName = \"Adrian\",\n  FeatureColNames = names(data)[!names(data) %in%\n                                  c(\"IDcol_1\", \"IDcol_2\",\"Adrian\")],\n  RandomColNumbers = NULL,\n  InteractionColNumbers = NULL,\n  WeightsColumn = NULL,\n  \n  # ML args\n  GridTune = FALSE,\n  GridStrategy = \"Cartesian\",\n  StoppingRounds = 10,\n  MaxRunTimeSecs = 3600 * 24 * 7,\n  MaxModelsInGrid = 10,\n  Distribution = \"binomial\",\n  Link = \"logit\",\n  RandomDistribution = NULL,\n  RandomLink = NULL,\n  Solver = \"AUTO\",\n  Alpha = NULL,\n  Lambda = NULL,\n  LambdaSearch = FALSE,\n  NLambdas = -1,\n  Standardize = TRUE,\n  RemoveCollinearColumns = FALSE,\n  InterceptInclude = TRUE,\n  NonNegativeCoefficients = FALSE)\n```\n \n\u003c/p\u003e\n\u003c/details\u003e \n\n\u003cdetails\u003e\u003csummary\u003eH2O-AutoML Example\u003c/summary\u003e\n\u003cp\u003e\n \n```r\n# Create some dummy correlated data with numeric and categorical features\ndata \u003c- AutoQuant::FakeDataGenerator(\n  Correlation = 0.85, \n  N = 1000L, \n  ID = 2L, \n  ZIP = 0L, \n  AddDate = FALSE, \n  Classification = TRUE, \n  MultiClass = FALSE)\n\nTestModel \u003c- AutoQuant::AutoH2oMLClassifier(\n   data,\n   TrainOnFull = FALSE,\n   ValidationData = NULL,\n   TestData = NULL,\n   TargetColumnName = \"Adrian\",\n   FeatureColNames = names(data)[!names(data) %in% c(\"IDcol_1\", \"IDcol_2\",\"Adrian\")],\n   ExcludeAlgos = NULL,\n   eval_metric = \"auc\",\n   Trees = 50,\n   MaxMem = \"32G\",\n   NThreads = max(1, parallel::detectCores()-2),\n   MaxModelsInGrid = 10,\n   model_path = normalizePath(\"./\"),\n   metadata_path = file.path(normalizePath(\"./\"), \"MetaData\"),\n   ModelID = \"FirstModel\",\n   NumOfParDepPlots = 3,\n   ReturnModelObjects = TRUE,\n   SaveModelObjects = FALSE,\n   IfSaveModel = \"mojo\",\n   H2OShutdown = FALSE,\n   HurdleModel = FALSE)\n```\n \n\u003c/p\u003e\n\u003c/details\u003e \n\n\u003cdetails\u003e\u003csummary\u003eH2O-GAM Example\u003c/summary\u003e\n\u003cp\u003e\n \n```r\n# Create some dummy correlated data\ndata \u003c- AutoQuant::FakeDataGenerator(\n  Correlation = 0.85,\n  N = 1000,\n  ID = 2,\n  ZIP = 0,\n  AddDate = FALSE,\n  Classification = TRUE,\n  MultiClass = FALSE)\n\n# Define GAM Columns to use - up to 9 are allowed\nGamCols \u003c- names(which(unlist(lapply(data, is.numeric))))\nGamCols \u003c- GamCols[!GamCols %in% c(\"Adrian\",\"IDcol_1\",\"IDcol_2\")]\nGamCols \u003c- GamCols[1L:(min(9L,length(GamCols)))]\n\n# Run function\nTestModel \u003c- AutoQuant::AutoH2oGAMClassifier(\n\n  # Compute management\n  MaxMem = {gc();paste0(as.character(floor(as.numeric(system(\"awk '/MemFree/ {print $2}' /proc/meminfo\", intern=TRUE)) / 1000000)),\"G\")},\n  NThreads = max(1, parallel::detectCores()-2),\n  H2OShutdown = TRUE,\n  H2OStartUp = TRUE,\n  IfSaveModel = \"mojo\",\n\n  # Model evaluation:\n  eval_metric = \"auc\",\n  NumOfParDepPlots = 3,\n\n  # Metadata arguments:\n  model_path = NULL,\n  metadata_path = NULL,\n  ModelID = \"FirstModel\",\n  ReturnModelObjects = TRUE,\n  SaveModelObjects = FALSE,\n  SaveInfoToPDF = FALSE,\n\n  # Data arguments:\n  data = data,\n  TrainOnFull = FALSE,\n  ValidationData = NULL,\n  TestData = NULL,\n  TargetColumnName = \"Adrian\",\n  FeatureColNames = names(data)[!names(data) %in% c(\"IDcol_1\", \"IDcol_2\",\"Adrian\")],\n  WeightsColumn = NULL,\n  GamColNames = GamCols,\n\n  # ML args\n  num_knots = NULL,\n  keep_gam_cols = TRUE,\n  GridTune = FALSE,\n  GridStrategy = \"Cartesian\",\n  StoppingRounds = 10,\n  MaxRunTimeSecs = 3600 * 24 * 7,\n  MaxModelsInGrid = 10,\n  Distribution = \"binomial\",\n  Link = \"logit\",\n  Solver = \"AUTO\",\n  Alpha = NULL,\n  Lambda = NULL,\n  LambdaSearch = FALSE,\n  NLambdas = -1,\n  Standardize = TRUE,\n  RemoveCollinearColumns = FALSE,\n  InterceptInclude = TRUE,\n  NonNegativeCoefficients = FALSE)\n```\n \n\u003c/p\u003e\n\u003c/details\u003e\n\n\u003c/p\u003e\n\u003c/details\u003e\n\n### MultiClass Classification\n\n\u003cdetails\u003e\u003csummary\u003eclick to expand\u003c/summary\u003e\n\u003cp\u003e\n\n\u003cdetails\u003e\u003csummary\u003eMultiClass Description\u003c/summary\u003e\n\u003cp\u003e\n  \nThe Auto_MultiClass() models handle a multitude of tasks. In order:\n1. Convert your data to data.table format for faster processing\n2. Create train, validation, and test data if you didn't supply those directly to the function\n3. Consoldate columns that are used for modeling and what is to be kept for data returned\n4. Dichotomize categorical variables (for AutoXGBoostRegression) and save the factor levels for scoring in a way that guarentees consistency across training, validation, and test data sets\n5. Saves the final column names for modeling to a csv for later reference\n6. Ensures the target levels are consistent across train, validate, and test sets and save the levels to file\n7. Handles the data conversion to the appropriate type, based on model type (CatBoost, H2O, and XGBoost)\n8. Multi-armed bandit hyperparameter tuning using randomized probability matching, if you choose to grid tune\n9. Build the grid tuned models\n10. Collect the evaluation metrics for each grid tune run\n11. Identify the best model of the set of models built in the grid tuning setup\n12. Save the hyperparameters from the winning grid tuned model\n13. Build the final model based on the best model from the grid tuning model search\n14. Collect evaluation metrics based on performance on test data\n15. Store the final predictions with the associated test data and other columns you want included in that set\n16. Generate and save Variable Importance data\n17. Return all the objects generated in a named list for immediate use\n\n\u003c/p\u003e\n\u003c/details\u003e\n\n\u003cdetails\u003e\u003csummary\u003eCatBoost Example\u003c/summary\u003e\n\u003cp\u003e\n\n```r\n# Create some dummy correlated data\ndata \u003c- AutoQuant::FakeDataGenerator(\n  Correlation = 0.85,\n  N = 10000L,\n  ID = 2L,\n  ZIP = 0L,\n  AddDate = FALSE,\n  Classification = FALSE,\n  MultiClass = TRUE)\n\n# Run function\nTestModel \u003c- AutoQuant::AutoCatBoostMultiClass(\n  \n  # GPU or CPU and the number of available GPUs\n  task_type = 'GPU',\n  NumGPUs = 1,\n  TrainOnFull = FALSE,\n  DebugMode = FALSE,\n  \n  # Metadata args\n  OutputSelection = c('Importances', 'EvalPlots', 'EvalMetrics', 'Score_TrainData'),\n  ModelID = 'Test_Model_1',\n  model_path = normalizePath('./'),\n  metadata_path = normalizePath('./'),\n  SaveModelObjects = FALSE,\n  ReturnModelObjects = TRUE,\n  \n  # Data args\n  data = data,\n  ValidationData = NULL,\n  TestData = NULL,\n  TargetColumnName = 'Adrian',\n  FeatureColNames = names(data)[!names(data) %in%\n                                  c('IDcol_1', 'IDcol_2','Adrian')],\n  PrimaryDateColumn = NULL,\n  WeightsColumnName = NULL,\n  ClassWeights = c(1L,1L,1L,1L,1L),\n  IDcols = c('IDcol_1','IDcol_2'),\n  \n  # Model evaluation\n  eval_metric = 'MCC',\n  loss_function = 'MultiClassOneVsAll',\n  grid_eval_metric = 'Accuracy',\n  MetricPeriods = 10L,\n  NumOfParDepPlots = 3,\n  \n  # Grid tuning args\n  PassInGrid = NULL,\n  GridTune = TRUE,\n  MaxModelsInGrid = 30L,\n  MaxRunsWithoutNewWinner = 20L,\n  MaxRunMinutes = 24L*60L,\n  BaselineComparison = 'default',\n  \n  # ML args\n  langevin = FALSE,\n  diffusion_temperature = 10000,\n  Trees = seq(100L, 500L, 50L),\n  Depth = seq(4L, 8L, 1L),\n  LearningRate = seq(0.01,0.10,0.01),\n  L2_Leaf_Reg = seq(1.0, 10.0, 1.0),\n  RandomStrength = 1,\n  BorderCount = 254,\n  RSM = c(0.80, 0.85, 0.90, 0.95, 1.0),\n  BootStrapType = c('Bayesian', 'Bernoulli', 'Poisson', 'MVS', 'No'),\n  GrowPolicy = c('SymmetricTree', 'Depthwise', 'Lossguide'),\n  model_size_reg = 0.5,\n  feature_border_type = 'GreedyLogSum',\n  sampling_unit = 'Object',\n  subsample = NULL,\n  score_function = 'Cosine',\n  min_data_in_leaf = 1)\n```\n\n\u003c/p\u003e\n\u003c/details\u003e\n\n\u003cdetails\u003e\u003csummary\u003eXGBoost Example\u003c/summary\u003e\n\u003cp\u003e\n\n```r\n# Create some dummy correlated data\ndata \u003c- AutoQuant::FakeDataGenerator(\n  Correlation = 0.85,\n  N = 1000L,\n  ID = 2L,\n  ZIP = 0L,\n  AddDate = FALSE,\n  Classification = FALSE,\n  MultiClass = TRUE)\n\n# Run function\nTestModel \u003c- AutoQuant::AutoXGBoostMultiClass(\n  \n  # GPU or CPU\n  TreeMethod = \"hist\",\n  NThreads = parallel::detectCores(),\n  \n  # Metadata args\n  OutputSelection = c(\"Importances\", \"EvalPlots\", \"EvalMetrics\", \"PDFs\", \"Score_TrainData\"),\n  model_path = normalizePath(\"./\"),\n  metadata_path = normalizePath(\"./\"),\n  ModelID = \"Test_Model_1\",\n  EncodingMethod = \"binary\",\n  ReturnFactorLevels = TRUE,\n  ReturnModelObjects = TRUE,\n  SaveModelObjects = FALSE,\n  \n  # Data args\n  data = data,\n  TrainOnFull = FALSE,\n  ValidationData = NULL,\n  TestData = NULL,\n  TargetColumnName = \"Adrian\",\n  FeatureColNames = names(data)[!names(data) %in%\n                                  c(\"IDcol_1\", \"IDcol_2\",\"Adrian\")],\n  WeightsColumnName = NULL,\n  IDcols = c(\"IDcol_1\",\"IDcol_2\"),\n  \n  # Model evaluation args\n  eval_metric = \"merror\",\n  LossFunction = 'multi:softprob',\n  grid_eval_metric = \"accuracy\",\n  NumOfParDepPlots = 3L,\n  \n  # Grid tuning args\n  PassInGrid = NULL,\n  GridTune = FALSE,\n  BaselineComparison = \"default\",\n  MaxModelsInGrid = 10L,\n  MaxRunsWithoutNewWinner = 20L,\n  MaxRunMinutes = 24L*60L,\n  Verbose = 1L,\n  DebugMode = FALSE,\n  \n  # ML args\n  Trees = 50L,\n  eta = 0.05,\n  max_depth = 4L,\n  min_child_weight = 1.0,\n  subsample = 0.55,\n  colsample_bytree = 0.55)\n```\n\n\u003c/p\u003e\n\u003c/details\u003e\n\n\u003cdetails\u003e\u003csummary\u003eLightGBM Example\u003c/summary\u003e\n\u003cp\u003e\n\n```r\n# Create some dummy correlated data\ndata \u003c- AutoQuant::FakeDataGenerator(\n  Correlation = 0.85,\n  N = 1000,\n  ID = 2,\n  ZIP = 0,\n  AddDate = FALSE,\n  Classification = FALSE,\n  MultiClass = FALSE)\n\n# Run function\nTestModel \u003c- AutoQuant::AutoLightGBMMultiClass(\n\n  # Metadata args\n  OutputSelection = c(\"Importances\",\"EvalPlots\",\"EvalMetrics\",\"Score_TrainData\"),\n  model_path = normalizePath(\"./\"),\n  metadata_path = NULL,\n  ModelID = \"Test_Model_1\",\n  NumOfParDepPlots = 3L,\n  EncodingMethod = \"credibility\",\n  ReturnFactorLevels = TRUE,\n  ReturnModelObjects = TRUE,\n  SaveModelObjects = FALSE,\n  SaveInfoToPDF = FALSE,\n  DebugMode = FALSE,\n\n  # Data args\n  data = data,\n  TrainOnFull = FALSE,\n  ValidationData = NULL,\n  TestData = NULL,\n  TargetColumnName = \"Adrian\",\n  FeatureColNames = names(data)[!names(data) %in% c(\"IDcol_1\", \"IDcol_2\",\"Adrian\")],\n  PrimaryDateColumn = NULL,\n  WeightsColumnName = NULL,\n  IDcols = c(\"IDcol_1\",\"IDcol_2\"),\n\n  # Grid parameters\n  GridTune = FALSE,\n  grid_eval_metric = 'microauc',\n  BaselineComparison = 'default',\n  MaxModelsInGrid = 10L,\n  MaxRunsWithoutNewWinner = 20L,\n  MaxRunMinutes = 24L*60L,\n  PassInGrid = NULL,\n\n  # Core parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#core-parameters\n  input_model = NULL, # continue training a model that is stored to file\n  task = \"train\",\n  device_type = 'CPU',\n  NThreads = parallel::detectCores() / 2,\n  objective = 'multiclass',\n  multi_error_top_k = 1,\n  metric = 'multi_logloss',\n  boosting = 'gbdt',\n  LinearTree = FALSE,\n  Trees = 50L,\n  eta = NULL,\n  num_leaves = 31,\n  deterministic = TRUE,\n\n  # Learning Parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#learning-control-parameters\n  force_col_wise = FALSE,\n  force_row_wise = FALSE,\n  max_depth = NULL,\n  min_data_in_leaf = 20,\n  min_sum_hessian_in_leaf = 0.001,\n  bagging_freq = 0,\n  bagging_fraction = 1.0,\n  feature_fraction = 1.0,\n  feature_fraction_bynode = 1.0,\n  extra_trees = FALSE,\n  early_stopping_round = 10,\n  first_metric_only = TRUE,\n  max_delta_step = 0.0,\n  lambda_l1 = 0.0,\n  lambda_l2 = 0.0,\n  linear_lambda = 0.0,\n  min_gain_to_split = 0,\n  drop_rate_dart = 0.10,\n  max_drop_dart = 50,\n  skip_drop_dart = 0.50,\n  uniform_drop_dart = FALSE,\n  top_rate_goss = FALSE,\n  other_rate_goss = FALSE,\n  monotone_constraints = NULL,\n  monotone_constraints_method = \"advanced\",\n  monotone_penalty = 0.0,\n  forcedsplits_filename = NULL, # use for AutoStack option; .json file\n  refit_decay_rate = 0.90,\n  path_smooth = 0.0,\n\n  # IO Dataset Parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#io-parameters\n  max_bin = 255,\n  min_data_in_bin = 3,\n  data_random_seed = 1,\n  is_enable_sparse = TRUE,\n  enable_bundle = TRUE,\n  use_missing = TRUE,\n  zero_as_missing = FALSE,\n  two_round = FALSE,\n\n  # Convert Parameters\n  convert_model = NULL,\n  convert_model_language = \"cpp\",\n\n  # Objective Parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#objective-parameters\n  boost_from_average = TRUE,\n  is_unbalance = FALSE,\n  scale_pos_weight = 1.0,\n\n  # Metric Parameters (metric is in Core)\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#metric-parameters\n  is_provide_training_metric = TRUE,\n  eval_at = c(1,2,3,4,5),\n\n  # Network Parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#network-parameters\n  num_machines = 1,\n\n  # GPU Parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#gpu-parameters\n  gpu_platform_id = -1,\n  gpu_device_id = -1,\n  gpu_use_dp = TRUE,\n  num_gpu = 1)\n```\n\n\u003c/p\u003e\n\u003c/details\u003e\n\n\u003cdetails\u003e\u003csummary\u003eH2O-GBM Example\u003c/summary\u003e\n\u003cp\u003e\n\n```r\n# Create some dummy correlated data\ndata \u003c- AutoQuant::FakeDataGenerator(\n  Correlation = 0.85,\n  N = 1000,\n  ID = 2,\n  ZIP = 0,\n  AddDate = FALSE,\n  Classification = FALSE,\n  MultiClass = TRUE)\n\n# Run function\nTestModel \u003c- AutoQuant::AutoH2oGBMMultiClass(\n   data,\n   TrainOnFull = FALSE,\n   ValidationData = NULL,\n   TestData = NULL,\n   TargetColumnName = \"Adrian\",\n   FeatureColNames = names(data)[!names(data) %in% c(\"IDcol_1\", \"IDcol_2\",\"Adrian\")],\n   WeightsColumn = NULL,\n   eval_metric = \"logloss\",\n   MaxMem = {gc();paste0(as.character(floor(as.numeric(system(\"awk '/MemFree/ {print $2}' /proc/meminfo\", intern=TRUE)) / 1000000)),\"G\")},\n   NThreads = max(1, parallel::detectCores()-2),\n   model_path = normalizePath(\"./\"),\n   metadata_path = file.path(normalizePath(\"./\")),\n   ModelID = \"FirstModel\",\n   ReturnModelObjects = TRUE,\n   SaveModelObjects = FALSE,\n   IfSaveModel = \"mojo\",\n   H2OShutdown = TRUE,\n   H2OStartUp = TRUE,\n\n   # Model args\n   GridTune = FALSE,\n   GridStrategy = \"Cartesian\",\n   MaxRuntimeSecs = 60*60*24,\n   StoppingRounds = 10,\n   MaxModelsInGrid = 2,\n   Trees = 50,\n   LearnRate = 0.10,\n   LearnRateAnnealing = 1,\n   eval_metric = \"RMSE\",\n   Distribution = \"multinomial\",\n   MaxDepth = 20,\n   SampleRate = 0.632,\n   ColSampleRate = 1,\n   ColSampleRatePerTree = 1,\n   ColSampleRatePerTreeLevel  = 1,\n   MinRows = 1,\n   NBins = 20,\n   NBinsCats = 1024,\n   NBinsTopLevel = 1024,\n   HistogramType = \"AUTO\",\n   CategoricalEncoding = \"AUTO\")\n```\n\n\u003c/p\u003e\n\u003c/details\u003e\n\n\u003cdetails\u003e\u003csummary\u003eH2O-DRF Example\u003c/summary\u003e\n\u003cp\u003e\n\n```r\n# Create some dummy correlated data\ndata \u003c- AutoQuant::FakeDataGenerator(\n  Correlation = 0.85,\n  N = 1000L,\n  ID = 2L,\n  ZIP = 0L,\n  AddDate = FALSE,\n  Classification = FALSE,\n  MultiClass = TRUE)\n\n# Run function\nTestModel \u003c- AutoQuant::AutoH2oDRFMultiClass(\n  data,\n  TrainOnFull = FALSE,\n  ValidationData = NULL,\n  TestData = NULL,\n  TargetColumnName = \"Adrian\",\n  FeatureColNames = names(data)[!names(data) %in% c(\"IDcol_1\", \"IDcol_2\",\"Adrian\")],\n  WeightsColumn = NULL,\n  eval_metric = \"logloss\",\n  MaxMem = {gc();paste0(as.character(floor(as.numeric(system(\"awk '/MemFree/ {print $2}' /proc/meminfo\", intern=TRUE)) / 1000000)),\"G\")},\n  NThreads = max(1, parallel::detectCores()-2),\n  model_path = normalizePath(\"./\"),\n  metadata_path = file.path(normalizePath(\"./\")),\n  ModelID = \"FirstModel\",\n  ReturnModelObjects = TRUE,\n  SaveModelObjects = FALSE,\n  IfSaveModel = \"mojo\",\n  H2OShutdown = FALSE,\n  H2OStartUp = TRUE,\n\n  # Grid Tuning Args\n  GridStrategy = \"Cartesian\",\n  GridTune = FALSE,\n  MaxModelsInGrid = 10,\n  MaxRuntimeSecs = 60*60*24,\n  StoppingRounds = 10,\n\n  # ML args\n  Trees = 50,\n  MaxDepth = 20,\n  SampleRate = 0.632,\n  MTries = -1,\n  ColSampleRatePerTree = 1,\n  ColSampleRatePerTreeLevel = 1,\n  MinRows = 1,\n  NBins = 20,\n  NBinsCats = 1024,\n  NBinsTopLevel = 1024,\n  HistogramType = \"AUTO\",\n  CategoricalEncoding = \"AUTO\")\n```\n\n\u003c/p\u003e\n\u003c/details\u003e\n\n\u003cdetails\u003e\u003csummary\u003eH2O-GLM Example\u003c/summary\u003e\n\u003cp\u003e\n\n```r\n# Create some dummy correlated data with numeric and categorical features\ndata \u003c- AutoQuant::FakeDataGenerator(\n  Correlation = 0.85,\n  N = 1000L,\n  ID = 2L,\n  ZIP = 0L,\n  AddDate = FALSE,\n  Classification = FALSE,\n  MultiClass = TRUE)\n\n# Run function\nTestModel \u003c- AutoQuant::AutoH2oGLMMultiClass(\n  \n  # Compute management\n  MaxMem = {gc();paste0(as.character(floor(as.numeric(system(\"awk '/MemFree/ {print $2}' /proc/meminfo\", intern=TRUE)) / 1000000)),\"G\")},\n  NThreads = max(1, parallel::detectCores()-2),\n  H2OShutdown = TRUE,\n  H2OStartUp = TRUE,\n  IfSaveModel = \"mojo\",\n  \n  # Model evaluation:\n  eval_metric = \"logloss\",\n  NumOfParDepPlots = 3,\n  \n  # Metadata arguments:\n  model_path = NULL,\n  metadata_path = NULL,\n  ModelID = \"FirstModel\",\n  ReturnModelObjects = TRUE,\n  SaveModelObjects = FALSE,\n  SaveInfoToPDF = FALSE,\n  \n  # Data arguments:\n  data = data,\n  TrainOnFull = FALSE,\n  ValidationData = NULL,\n  TestData = NULL,\n  TargetColumnName = \"Adrian\",\n  FeatureColNames = names(data)[!names(data) %in% c(\"IDcol_1\", \"IDcol_2\",\"Adrian\")],\n  RandomColNumbers = NULL,\n  InteractionColNumbers = NULL,\n  WeightsColumn = NULL,\n  \n  # Model args\n  GridTune = FALSE,\n  GridStrategy = \"Cartesian\",\n  StoppingRounds = 10,\n  MaxRunTimeSecs = 3600 * 24 * 7,\n  MaxModelsInGrid = 10,\n  Distribution = \"multinomial\",\n  Link = \"family_default\",\n  RandomDistribution = NULL,\n  RandomLink = NULL,\n  Solver = \"AUTO\",\n  Alpha = NULL,\n  Lambda = NULL,\n  LambdaSearch = FALSE,\n  NLambdas = -1,\n  Standardize = TRUE,\n  RemoveCollinearColumns = FALSE,\n  InterceptInclude = TRUE,\n  NonNegativeCoefficients = FALSE)\n```\n\n\u003c/p\u003e\n\u003c/details\u003e\n\n\u003cdetails\u003e\u003csummary\u003eH2O-AutoML Example\u003c/summary\u003e\n\u003cp\u003e\n\n```r\n# Create some dummy correlated data with numeric and categorical features\ndata \u003c- AutoQuant::FakeDataGenerator(Correlation = 0.85, N = 1000, ID = 2, ZIP = 0, AddDate = FALSE, Classification = FALSE, MultiClass = TRUE)\n\n# Run function\nTestModel \u003c- AutoQuant::AutoH2oMLMultiClass(\n   data,\n   TrainOnFull = FALSE,\n   ValidationData = NULL,\n   TestData = NULL,\n   TargetColumnName = \"Adrian\",\n   FeatureColNames = names(data)[!names(data) %in% c(\"IDcol_1\", \"IDcol_2\",\"Adrian\")],\n   ExcludeAlgos = NULL,\n   eval_metric = \"logloss\",\n   Trees = 50,\n   MaxMem = \"32G\",\n   NThreads = max(1, parallel::detectCores()-2),\n   MaxModelsInGrid = 10,\n   model_path = normalizePath(\"./\"),\n   metadata_path = file.path(normalizePath(\"./\"), \"MetaData\"),\n   ModelID = \"FirstModel\",\n   ReturnModelObjects = TRUE,\n   SaveModelObjects = FALSE,\n   IfSaveModel = \"mojo\",\n   H2OShutdown = FALSE,\n   HurdleModel = FALSE)\n```\n\n\u003c/p\u003e\n\u003c/details\u003e\n\n\u003cdetails\u003e\u003csummary\u003eH2O-GAM Example\u003c/summary\u003e\n\u003cp\u003e\n\n```r\n# Create some dummy correlated data with numeric and categorical features\ndata \u003c- AutoQuant::FakeDataGenerator(\n  Correlation = 0.85,\n  N = 1000L,\n  ID = 2L,\n  ZIP = 0L,\n  AddDate = FALSE,\n  Classification = FALSE,\n  MultiClass = TRUE)\n\n# Define GAM Columns to use - up to 9 are allowed\nGamCols \u003c- names(which(unlist(lapply(data, is.numeric))))\nGamCols \u003c- GamCols[!GamCols %in% c(\"Adrian\",\"IDcol_1\",\"IDcol_2\")]\nGamCols \u003c- GamCols[1L:(min(9L,length(GamCols)))]\n\n# Run function\nTestModel \u003c- AutoQuant::AutoH2oGAMMultiClass(\n  data,\n  TrainOnFull = FALSE,\n  ValidationData = NULL,\n  TestData = NULL,\n  TargetColumnName = \"Adrian\",\n  FeatureColNames = names(data)[!names(data) %in% c(\"IDcol_1\", \"IDcol_2\",\"Adrian\")],\n  WeightsColumn = NULL,\n  GamColNames = GamCols,\n  eval_metric = \"logloss\",\n  MaxMem = {gc();paste0(as.character(floor(as.numeric(system(\"awk '/MemFree/ {print $2}' /proc/meminfo\", intern=TRUE)) / 1000000)),\"G\")},\n  NThreads = max(1, parallel::detectCores()-2),\n  model_path = normalizePath(\"./\"),\n  metadata_path = NULL,\n  ModelID = \"FirstModel\",\n  ReturnModelObjects = TRUE,\n  SaveModelObjects = FALSE,\n  IfSaveModel = \"mojo\",\n  H2OShutdown = FALSE,\n  H2OStartUp = TRUE,\n  \n  # ML args\n  num_knots = NULL,\n  keep_gam_cols = TRUE,\n  GridTune = FALSE,\n  GridStrategy = \"Cartesian\",\n  StoppingRounds = 10,\n  MaxRunTimeSecs = 3600 * 24 * 7,\n  MaxModelsInGrid = 10,\n  Distribution = \"multinomial\",\n  Link = \"Family_Default\",\n  Solver = \"AUTO\",\n  Alpha = NULL,\n  Lambda = NULL,\n  LambdaSearch = FALSE,\n  NLambdas = -1,\n  Standardize = TRUE,\n  RemoveCollinearColumns = FALSE,\n  InterceptInclude = TRUE,\n  NonNegativeCoefficients = FALSE)\n```\n\n\u003c/p\u003e\n\u003c/details\u003e\n\n\u003c/p\u003e\n\u003c/details\u003e\n\n\n\n\u003c/p\u003e\n\u003c/details\u003e\n\n\n\n\u003c/p\u003e\n\u003c/details\u003e\n\n\n\n## Model Scoring \u003cimg src=\"https://raw.githubusercontent.com/AdrianAntico/AutoQuant/master/Images/ModelScoringImage.png\" align=\"right\" width=\"80\" /\u003e\n\u003cdetails\u003e\u003csummary\u003eExpand to view content\u003c/summary\u003e\n\u003cp\u003e\n\n\n\n\u003cdetails\u003e\u003csummary\u003eScoring Description\u003c/summary\u003e\n\u003cp\u003e\n\n\u003ccode\u003eAutoCatBoostScoring()\u003c/code\u003e is an automated scoring function that compliments the AutoCatBoost__() model training functions. This function requires you to supply features for scoring. It will run ModelDataPrep() to prepare your features for catboost data conversion and scoring. It will also handle and transformations and back-transformations if you utilized that feature in the regression training case.\n\n\u003ccode\u003eAutoXGBoostScoring()\u003c/code\u003e is an automated scoring function that compliments the AutoXGBoost__() model training functions. This function requires you to supply features for scoring. It will run ModelDataPrep() and the CategoricalEncoding() functions to prepare your features for xgboost data conversion and scoring. It will also handle and transformations and back-transformations if you utilized that feature in the regression training case.\n\n\u003ccode\u003eAutoLightGBMScoring()\u003c/code\u003e is an automated scoring function that compliments the AutoLightGBM__() model training functions. This function requires you to supply features for scoring. It will run ModelDataPrep() and the CategoricalEncoding() functions to prepare your features for lightgbm data conversion and scoring. It will also handle and transformations and back-transformations if you utilized that feature in the regression training case.\n\n\u003ccode\u003eAutoH2OMLScoring()\u003c/code\u003e is an automated scoring function that compliments the AutoH2oGBM__() and AutoH2oDRF__() model training functions. This function requires you to supply features for scoring. It will run ModelDataPrep()to prepare your features for H2O data conversion and scoring. It will also handle transformations and back-transformations if you utilized that feature in the regression training case and didn't do it yourself before hand.\n\n\u003ccode\u003eAutoCatBoostHurdleModelScoring()\u003c/code\u003e for scoring models developed with AutoCatBoostHurdleModel()\n\n\u003ccode\u003eAutoLightGBMHurdleModelScoring()\u003c/code\u003e for scoring models developed with AutoLightGBMHurdleModel()\n\n\u003ccode\u003eAutoXGBoostHurdleModelScoring()\u003c/code\u003e for scoring models developed with AutoXGBoostHurdleModel()\n\n\u003c/p\u003e\n\u003c/details\u003e\n\n\n\n\u003cdetails\u003e\u003csummary\u003eAutoCatBoost__() Examples\u003c/summary\u003e\n\u003cp\u003e\n\n\u003cdetails\u003e\u003csummary\u003eAutoCatBoostRegression() Scoring Example\u003c/summary\u003e\n\u003cp\u003e\n\n```r\n# Create some dummy correlated data\ndata \u003c- AutoQuant::FakeDataGenerator(\n  Correlation = 0.85,\n  N = 10000,\n  ID = 2,\n  ZIP = 0,\n  AddDate = FALSE,\n  Classification = FALSE,\n  MultiClass = FALSE)\n\n# Copy data\ndata1 \u003c- data.table::copy(data)\n\n# Feature Colnames\nFeatures \u003c- names(data1)[!names(data1) %in% c(\"IDcol_1\", \"IDcol_2\",\"DateTime\",\"Adrian\")]\n\n# Run function\nTestModel \u003c- AutoQuant::AutoCatBoostRegression(\n  \n  # GPU or CPU and the number of available GPUs\n  TrainOnFull = FALSE,\n  task_type = 'CPU',\n  NumGPUs = 1,\n  DebugMode = FALSE,\n  \n  # Metadata args\n  OutputSelection = c('Importances','EvalPlots','EvalMetrics','Score_TrainData'),\n  ModelID = 'Test_Model_1',\n  model_path = getwd(),\n  metadata_path = getwd(),\n  SaveModelObjects = FALSE,\n  SaveInfoToPDF = FALSE,\n  ReturnModelObjects = TRUE,\n  \n  # Data args\n  data = data1,\n  ValidationData = NULL,\n  TestData = NULL,\n  TargetColumnName = 'Adrian',\n  FeatureColNames = Features,\n  PrimaryDateColumn = NULL,\n  WeightsColumnName = NULL,\n  IDcols = c('IDcol_1','IDcol_2'),\n  TransformNumericColumns = 'Adrian',\n  Methods = c('Asinh','Asin','Log','LogPlus1','Sqrt','Logit'),\n  \n  # Model evaluation\n  eval_metric = 'RMSE',\n  eval_metric_value = 1.5,\n  loss_function = 'RMSE',\n  loss_function_value = 1.5,\n  MetricPeriods = 10L,\n  NumOfParDepPlots = ncol(data1)-1L-2L,\n  \n  # Grid tuning args\n  PassInGrid = NULL,\n  GridTune = FALSE,\n  MaxModelsInGrid = 30L,\n  MaxRunsWithoutNewWinner = 20L,\n  MaxRunMinutes = 60*60,\n  BaselineComparison = 'default',\n  \n  # ML args\n  langevin = FALSE,\n  diffusion_temperature = 10000,\n  Trees = 1000,\n  Depth = 9,\n  L2_Leaf_Reg = NULL,\n  RandomStrength = 1,\n  BorderCount = 128,\n  LearningRate = NULL,\n  RSM = 1,\n  BootStrapType = NULL,\n  GrowPolicy = 'SymmetricTree',\n  model_size_reg = 0.5,\n  feature_border_type = 'GreedyLogSum',\n  sampling_unit = 'Object',\n  subsample = NULL,\n  score_function = 'Cosine',\n  min_data_in_leaf = 1)\n\n\n# Insights Report\nAutoQuant::ModelInsightsReport(\n  \n  # Meta info\n  TargetColumnName = 'Adrian',\n  PredictionColumnName = 'Predict',\n  FeatureColumnNames = Features,\n  DateColumnName = NULL,\n  \n  # Control options\n  TargetType = 'regression',\n  ModelID = 'Test_Model_1',\n  Algo = 'catboost',\n  OutputPath = getwd(),\n  ModelObject = TestModel)\n\n\n# Score data\nPreds \u003c- AutoQuant::AutoCatBoostScoring(\n  TargetType = 'regression',\n  ScoringData = data,\n  FeatureColumnNames = Features,\n  FactorLevelsList = TestModel$FactorLevelsList,\n  IDcols = c('IDcol_1','IDcol_2'),\n  OneHot = FALSE,\n  ReturnShapValues = TRUE,\n  ModelObject = TestModel$Model,\n  ModelPath = NULL,\n  ModelID = 'Test_Model_1',\n  ReturnFeatures = TRUE,\n  MultiClassTargetLevels = NULL,\n  TransformNumeric = FALSE,\n  BackTransNumeric = FALSE,\n  TargetColumnName = NULL,\n  TransformationObject = NULL,\n  TransID = NULL,\n  TransPath = NULL,\n  MDP_Impute = TRUE,\n  MDP_CharToFactor = TRUE,\n  MDP_RemoveDates = TRUE,\n  MDP_MissFactor = '0',\n  MDP_MissNum = -1,\n  RemoveModel = FALSE)\n```\n\n\u003c/p\u003e\n\u003c/details\u003e\n\n\u003cdetails\u003e\u003csummary\u003eAutoCatBoostClassifier() Scoring Example\u003c/summary\u003e\n\u003cp\u003e\n\n```r\n# Refresh data\ndata \u003c- AutoQuant::FakeDataGenerator(\n  Correlation = 0.85,\n  N = 25000L,\n  ID = 2L,\n  AddWeightsColumn = TRUE,\n  ZIP = 0L,\n  AddDate = TRUE,\n  Classification = TRUE,\n  MultiClass = FALSE)\n\n# Copy data (used for scoring below``)\ndata1 \u003c- data.table::copy(data)\n\n# Partition Data\nSets \u003c- Rodeo::AutoDataPartition(\n  data = data,\n  NumDataSets = 3,\n  Ratios = c(0.7,0.2,0.1),\n  PartitionType = \"random\",\n  StratifyColumnNames = \"Adrian\",\n  TimeColumnName = NULL)\nTTrainData \u003c- Sets$TrainData\nVValidationData \u003c- Sets$ValidationData\nTTestData \u003c- Sets$TestData\nrm(Sets)\n\n# Feature Colnames\nFeatures \u003c- names(TTrainData)[!names(TTrainData) %in% c(\"IDcol_1\", \"IDcol_2\",\"DateTime\",\"Adrian\")]\n\n# AutoCatBoostClassifier\nTestModel \u003c- AutoQuant::AutoCatBoostClassifier(\n  \n  # GPU or CPU and the number of available GPUs\n  task_type = \"CPU\",\n  NumGPUs = 1,\n  \n  # Metadata arguments\n  OutputSelection = c(\"Importances\", \"EvalPlots\", \"EvalMetrics\", \"Score_TrainData\"),\n  ModelID = \"Test_Model_1\",\n  model_path = normalizePath(\"./\"),\n  metadata_path = normalizePath(\"./\"),\n  SaveModelObjects = FALSE,\n  ReturnModelObjects = TRUE,\n  SaveInfoToPDF = FALSE,\n  \n  # Data arguments\n  data = TTrainData,\n  TrainOnFull = FALSE,\n  ValidationData = VValidationData,\n  TestData = TTestData,\n  TargetColumnName = \"Adrian\",\n  FeatureColNames = Features,\n  PrimaryDateColumn = \"DateTime\",\n  WeightsColumnName = \"Weights\",\n  ClassWeights = c(1L,1L),\n  IDcols = c(\"IDcol_1\",\"IDcol_2\",\"DateTime\"),\n  \n  # Model evaluation\n  CostMatrixWeights = c(2,0,0,1),\n  EvalMetric = \"MCC\",\n  LossFunction = \"Logloss\",\n  grid_eval_metric = \"Utility\",\n  MetricPeriods = 10L,\n  NumOfParDepPlots = 3,\n  \n  # Grid tuning arguments\n  PassInGrid = NULL,\n  GridTune = FALSE,\n  MaxModelsInGrid = 30L,\n  MaxRunsWithoutNewWinner = 20L,\n  MaxRunMinutes = 24L*60L,\n  BaselineComparison = \"default\",\n  \n  # ML args\n  Trees = 100L,\n  Depth = 4L,\n  LearningRate = NULL,\n  L2_Leaf_Reg = NULL,\n  RandomStrength = 1,\n  BorderCount = 128,\n  RSM = 0.80,\n  BootStrapType = \"Bayesian\",\n  GrowPolicy = \"SymmetricTree\",\n  langevin = FALSE,\n  diffusion_temperature = 10000,\n  model_size_reg = 0.5,\n  feature_border_type = \"GreedyLogSum\",\n  sampling_unit = \"Object\",\n  subsample = NULL,\n  score_function = \"Cosine\",\n  min_data_in_leaf = 1,\n  DebugMode = TRUE)\n\n\n# Insights Report\nAutoQuant::ModelInsightsReport(\n  \n  # Meta info\n  TargetColumnName = 'Adrian',\n  PredictionColumnName = 'p1',\n  FeatureColumnNames = Features,\n  DateColumnName = NULL,\n  \n  # Control options\n  TargetType = 'classification',\n  ModelID = 'Test_Model_1',\n  Algo = 'catboost',\n  OutputPath = getwd(),\n  ModelObject = TestModel)\n\n\n# Score data\nPreds \u003c- AutoQuant::AutoCatBoostScoring(\n  TargetType = 'classifier',\n  ScoringData = data,\n  FeatureColumnNames = Features,\n  FactorLevelsList = TestModel$FactorLevelsList,\n  IDcols = c(\"IDcol_1\",\"IDcol_2\",\"DateTime\"),\n  OneHot = FALSE,\n  ReturnShapValues = TRUE,\n  ModelObject = TestModel$Model,\n  ModelPath = NULL,\n  ModelID = 'Test_Model_1',\n  ReturnFeatures = TRUE,\n  MultiClassTargetLevels = NULL,\n  TransformNumeric = FALSE,\n  BackTransNumeric = FALSE,\n  TargetColumnName = NULL,\n  TransformationObject = NULL,\n  TransID = NULL,\n  TransPath = NULL,\n  MDP_Impute = TRUE,\n  MDP_CharToFactor = TRUE,\n  MDP_RemoveDates = TRUE,\n  MDP_MissFactor = '0',\n  MDP_MissNum = -1,\n  RemoveModel = FALSE)\n```\n\n\u003c/p\u003e\n\u003c/details\u003e\n\n\u003cdetails\u003e\u003csummary\u003eAutoCatBoostMultiClasss() Scoring Example\u003c/summary\u003e\n\u003cp\u003e\n\n```r\n# Refresh data\ndata \u003c- AutoQuant::FakeDataGenerator(\n  Correlation = 0.85,\n  N = 25000L,\n  ID = 2L,\n  AddWeightsColumn = TRUE,\n  ZIP = 0L,\n  AddDate = TRUE,\n  Classification = FALSE,\n  MultiClass = TRUE)\n\n# Copy data (used for scoring below``)\ndata1 \u003c- data.table::copy(data)\n\n# Partition Data\nSets \u003c- Rodeo::AutoDataPartition(\n  data = data,\n  NumDataSets = 3,\n  Ratios = c(0.7,0.2,0.1),\n  PartitionType = \"random\",\n  StratifyColumnNames = \"Adrian\",\n  TimeColumnName = NULL)\nTTrainData \u003c- Sets$TrainData\nVValidationData \u003c- Sets$ValidationData\nTTestData \u003c- Sets$TestData\nrm(Sets)\n\n# Feature Colnames\nFeatures \u003c- names(TTrainData)[!names(TTrainData) %in% c(\"IDcol_1\", \"IDcol_2\",\"Adrian\",\"DateTime\")]\n\n# Run function\nTestModel \u003c- AutoQuant::AutoCatBoostMultiClass(\n  \n  # GPU or CPU and the number of available GPUs\n  task_type = \"GPU\",\n  NumGPUs = 1,\n  \n  # Metadata arguments\n  OutputSelection = c(\"Importances\", \"EvalPlots\", \"EvalMetrics\", \"Score_TrainData\"),\n  ModelID = \"Test_Model_1\",\n  model_path = normalizePath(\"./\"),\n  metadata_path = normalizePath(\"./\"),\n  SaveModelObjects = FALSE,\n  ReturnModelObjects = TRUE,\n  \n  # Data arguments\n  data = TTrainData,\n  TrainOnFull = FALSE,\n  ValidationData = VValidationData,\n  TestData = TTestData,\n  TargetColumnName = \"Adrian\",\n  FeatureColNames = Features,\n  PrimaryDateColumn = \"DateTime\",\n  WeightsColumnName = \"Weights\",\n  ClassWeights = c(1L,1L,1L,1L,1L),\n  IDcols = c(\"IDcol_1\",\"IDcol_2\",\"DateTime\"),\n  \n  # Model evaluation\n  eval_metric = \"MCC\",\n  loss_function = \"MultiClassOneVsAll\",\n  grid_eval_metric = \"Accuracy\",\n  MetricPeriods = 10L,\n  \n  # Grid tuning arguments\n  PassInGrid = NULL,\n  GridTune = FALSE,\n  MaxModelsInGrid = 30L,\n  MaxRunsWithoutNewWinner = 20L,\n  MaxRunMinutes = 24L*60L,\n  BaselineComparison = \"default\",\n  \n  # ML args\n  Trees = 100L,\n  Depth = 4L,\n  LearningRate = 0.01,\n  L2_Leaf_Reg = 1.0,\n  RandomStrength = 1,\n  BorderCount = 128,\n  langevin = FALSE,\n  diffusion_temperature = 10000,\n  RSM = 0.80,\n  BootStrapType = \"Bayesian\",\n  GrowPolicy = \"SymmetricTree\",\n  model_size_reg = 0.5,\n  feature_border_type = \"GreedyLogSum\",\n  sampling_unit = \"Group\",\n  subsample = NULL,\n  score_function = \"Cosine\",\n  min_data_in_leaf = 1,\n  DebugMode = TRUE)\n\n\n# Insights Report\nAutoQuant::ModelInsightsReport(\n  \n  # Meta info\n  TargetColumnName = 'Adrian',\n  PredictionColumnName = 'Predict',\n  FeatureColumnNames = Features,\n  DateColumnName = NULL,\n  \n  # Control options\n  TargetType = 'multiclass',\n  ModelID = 'Test_Model_1',\n  Algo = 'catboost',\n  OutputPath = getwd(),\n  ModelObject = TestModel)\n\n\n# Score data\nPreds \u003c- AutoQuant::AutoCatBoostScoring(\n  TargetType = 'multiclass',\n  ScoringData = data,\n  FeatureColumnNames = Features,\n  FactorLevelsList = TestModel$FactorLevelsList,\n  IDcols = c(\"IDcol_1\",\"IDcol_2\",\"DateTime\"),\n  OneHot = FALSE,\n  ReturnShapValues = FALSE,\n  ModelObject = TestModel$Model,\n  ModelPath = NULL,\n  ModelID = 'Test_Model_1',\n  ReturnFeatures = TRUE,\n  MultiClassTargetLevels = TestModel$TargetLevels,\n  TransformNumeric = FALSE,\n  BackTransNumeric = FALSE,\n  TargetColumnName = NULL,\n  TransformationObject = NULL,\n  TransID = NULL,\n  TransPath = NULL,\n  MDP_Impute = TRUE,\n  MDP_CharToFactor = TRUE,\n  MDP_RemoveDates = TRUE,\n  MDP_MissFactor = '0',\n  MDP_MissNum = -1,\n  RemoveModel = FALSE)\n```\n\n\u003c/p\u003e\n\u003c/details\u003e\n\n\u003c/p\u003e\n\u003c/details\u003e\n\n\n\n\u003cdetails\u003e\u003csummary\u003eAutoLightGBM__() Examples\u003c/summary\u003e\n\u003cp\u003e\n\n\u003cdetails\u003e\u003csummary\u003eAutoLightGBMRegression() Scoring Example\u003c/summary\u003e\n\u003cp\u003e\n\n```r\n# Refresh data\ndata \u003c- AutoQuant::FakeDataGenerator(\n  Correlation = 0.85,\n  N = 25000L,\n  ID = 2L,\n  AddWeightsColumn = TRUE,\n  ZIP = 0L,\n  AddDate = TRUE,\n  Classification = FALSE,\n  MultiClass = FALSE)\n\n# Partition Data\nSets \u003c- Rodeo::AutoDataPartition(\n  data = data,\n  NumDataSets = 3,\n  Ratios = c(0.7,0.2,0.1),\n  PartitionType = \"random\",\n  StratifyColumnNames = \"Adrian\",\n  TimeColumnName = NULL)\nTTrainData \u003c- Sets$TrainData\nVValidationData \u003c- Sets$ValidationData\nTTestData \u003c- Sets$TestData\nrm(Sets)\n\n# Run function\nTestModel \u003c- AutoQuant::AutoLightGBMRegression(\n  \n  # GPU or CPU\n  NThreads = parallel::detectCores(),\n  \n  # Metadata args\n  OutputSelection = c(\"Importances\",\"EvalPlots\",\"EvalMetrics\",\"Score_TrainData\"),\n  model_path = getwd(),\n  metadata_path = getwd(),\n  ModelID = \"Test_Model_1\",\n  NumOfParDepPlots = 3L,\n  EncodingMethod = \"credibility\",\n  ReturnFactorLevels = TRUE,\n  ReturnModelObjects = TRUE,\n  SaveModelObjects = TRUE,\n  SaveInfoToPDF = FALSE,\n  DebugMode = TRUE,\n  \n  # Data args\n  data = TTrainData,\n  TrainOnFull = FALSE,\n  ValidationData = VValidationData,\n  TestData = TTestData,\n  TargetColumnName = \"Adrian\",\n  FeatureColNames = names(TTrainData)[!names(TTrainData) %in% c(\"IDcol_1\", \"IDcol_2\",\"DateTime\",\"Adrian\")],\n  PrimaryDateColumn = \"DateTime\",\n  WeightsColumnName = \"Weights\",\n  IDcols = c(\"IDcol_1\",\"IDcol_2\",\"DateTime\"),\n  TransformNumericColumns = NULL,\n  Methods = c(\"Asinh\",\"Asin\",\"Log\",\"LogPlus1\",\"Sqrt\",\"Logit\"),\n  \n  # Grid parameters\n  GridTune = FALSE,\n  grid_eval_metric = \"r2\",\n  BaselineComparison = \"default\",\n  MaxModelsInGrid = 10L,\n  MaxRunsWithoutNewWinner = 20L,\n  MaxRunMinutes = 24L*60L,\n  PassInGrid = NULL,\n  \n  # Core parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#core-parameters\n  input_model = NULL, # continue training a model that is stored to file\n  task = \"train\",\n  device_type = \"CPU\",\n  objective = 'regression',\n  metric = \"rmse\",\n  boosting = \"gbdt\",\n  LinearTree = FALSE,\n  Trees = 50L,\n  eta = NULL,\n  num_leaves = 31,\n  deterministic = TRUE,\n  \n  # Learning Parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#learning-control-parameters\n  force_col_wise = FALSE,\n  force_row_wise = FALSE,\n  max_depth = 6,\n  min_data_in_leaf = 20,\n  min_sum_hessian_in_leaf = 0.001,\n  bagging_freq = 1.0,\n  bagging_fraction = 1.0,\n  feature_fraction = 1.0,\n  feature_fraction_bynode = 1.0,\n  lambda_l1 = 0.0,\n  lambda_l2 = 0.0,\n  extra_trees = FALSE,\n  early_stopping_round = 10,\n  first_metric_only = TRUE,\n  max_delta_step = 0.0,\n  linear_lambda = 0.0,\n  min_gain_to_split = 0,\n  drop_rate_dart = 0.10,\n  max_drop_dart = 50,\n  skip_drop_dart = 0.50,\n  uniform_drop_dart = FALSE,\n  top_rate_goss = FALSE,\n  other_rate_goss = FALSE,\n  monotone_constraints = NULL,\n  monotone_constraints_method = \"advanced\",\n  monotone_penalty = 0.0,\n  forcedsplits_filename = NULL, # use for AutoStack option; .json file\n  refit_decay_rate = 0.90,\n  path_smooth = 0.0,\n  \n  # IO Dataset Parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#io-parameters\n  max_bin = 255,\n  min_data_in_bin = 3,\n  data_random_seed = 1,\n  is_enable_sparse = TRUE,\n  enable_bundle = TRUE,\n  use_missing = TRUE,\n  zero_as_missing = FALSE,\n  two_round = FALSE,\n  \n  # Convert Parameters\n  convert_model = NULL,\n  convert_model_language = \"cpp\",\n  \n  # Objective Parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#objective-parameters\n  boost_from_average = TRUE,\n  alpha = 0.90,\n  fair_c = 1.0,\n  poisson_max_delta_step = 0.70,\n  tweedie_variance_power = 1.5,\n  lambdarank_truncation_level = 30,\n  \n  # Metric Parameters (metric is in Core)\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#metric-parameters\n  is_provide_training_metric = TRUE,\n  eval_at = c(1,2,3,4,5),\n  \n  # Network Parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#network-parameters\n  num_machines = 1,\n  \n  # GPU Parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#gpu-parameters\n  gpu_platform_id = -1,\n  gpu_device_id = -1,\n  gpu_use_dp = TRUE,\n  num_gpu = 1)\n\n# Outcome\nModelID = \"Test_Model_1\"\ncolnames \u003c- data.table::fread(file = file.path(getwd(), paste0(ModelID, \"_ColNames.csv\")))\nPreds \u003c- AutoQuant::AutoLightGBMScoring(\n  TargetType = \"regression\",\n  ScoringData = TTestData,\n  ReturnShapValues = FALSE,\n  FeatureColumnNames = colnames[[1L]],\n  IDcols = c(\"IDcol_1\",\"IDcol_2\"),\n  EncodingMethod = \"credibility\",\n  FactorLevelsList = NULL,\n  TargetLevels = NULL,\n  ModelObject = NULL,\n  ModelPath = getwd(),\n  ModelID = \"Test_Model_1\",\n  ReturnFeatures = TRUE,\n  TransformNumeric = FALSE,\n  BackTransNumeric = FALSE,\n  TargetColumnName = NULL,\n  TransformationObject = NULL,\n  TransID = NULL,\n  TransPath = NULL,\n  MDP_Impute = TRUE,\n  MDP_CharToFactor = TRUE,\n  MDP_RemoveDates = TRUE,\n  MDP_MissFactor = \"0\",\n  MDP_MissNum = -1)\n```\n\n\u003c/p\u003e\n\u003c/details\u003e\n\n\u003cdetails\u003e\u003csummary\u003eAutoLightGBMClassifier() Scoring Example\u003c/summary\u003e\n\u003cp\u003e\n\n```r\n# Refresh data\ndata \u003c- AutoQuant::FakeDataGenerator(\n  Correlation = 0.85,\n  N = 25000L,\n  ID = 2L,\n  AddWeightsColumn = TRUE,\n  ZIP = 0L,\n  AddDate = TRUE,\n  Classification = TRUE,\n  MultiClass = FALSE)\n\n# Partition Data\nSets \u003c- Rodeo::AutoDataPartition(\n  data = data,\n  NumDataSets = 3,\n  Ratios = c(0.7,0.2,0.1),\n  PartitionType = \"random\",\n  StratifyColumnNames = \"Adrian\",\n  TimeColumnName = NULL)\nTTrainData \u003c- Sets$TrainData\nVValidationData \u003c- Sets$ValidationData\nTTestData \u003c- Sets$TestData\nrm(Sets)\n\n# Run function\nTestModel \u003c- AutoQuant::AutoLightGBMClassifier(\n  \n  # Multithreading\n  NThreads = parallel::detectCores(),\n  \n  # Metadata args\n  OutputSelection = c(\"Importances\",\"EvalPlots\",\"EvalMetrics\",\"Score_TrainData\"),\n  model_path = normalizePath(\"./\"),\n  metadata_path = NULL,\n  ModelID = \"Test_Model_1\",\n  NumOfParDepPlots = 3L,\n  EncodingMethod = \"credibility\",\n  ReturnFactorLevels = TRUE,\n  ReturnModelObjects = TRUE,\n  SaveModelObjects = TRUE,\n  SaveInfoToPDF = FALSE,\n  DebugMode = TRUE,\n  \n  # Data args\n  data = TTrainData,\n  TrainOnFull = FALSE,\n  ValidationData = VValidationData,\n  TestData = TTestData,\n  TargetColumnName = \"Adrian\",\n  FeatureColNames = names(TTrainData)[!names(TTrainData) %in% c(\"IDcol_1\", \"IDcol_2\",\"DateTime\",\"Adrian\")],\n  PrimaryDateColumn = NULL,\n  WeightsColumnName = \"Weights\",\n  IDcols = c(\"IDcol_1\",\"IDcol_2\",\"DateTime\"),\n  CostMatrixWeights = c(1,0,0,1),\n  \n  # Grid parameters\n  GridTune = FALSE,\n  grid_eval_metric = \"Utility\",\n  BaselineComparison = \"default\",\n  MaxModelsInGrid = 10L,\n  MaxRunsWithoutNewWinner = 20L,\n  MaxRunMinutes = 24L*60L,\n  PassInGrid = NULL,\n  \n  # Core parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#core-parameters\n  input_model = NULL, # continue training a model that is stored to file\n  task = \"train\",\n  device_type = \"CPU\",\n  objective = 'binary',\n  metric = 'binary_logloss',\n  boosting = \"gbdt\",\n  LinearTree = FALSE,\n  Trees = 50L,\n  eta = NULL,\n  num_leaves = 31,\n  deterministic = TRUE,\n  \n  # Learning Parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#learning-control-parameters\n  force_col_wise = FALSE,\n  force_row_wise = FALSE,\n  max_depth = 6,\n  min_data_in_leaf = 20,\n  min_sum_hessian_in_leaf = 0.001,\n  bagging_freq = 1.0,\n  bagging_fraction = 1.0,\n  feature_fraction = 1.0,\n  feature_fraction_bynode = 1.0,\n  lambda_l1 = 0.0,\n  lambda_l2 = 0.0,\n  extra_trees = FALSE,\n  early_stopping_round = 10,\n  first_metric_only = TRUE,\n  max_delta_step = 0.0,\n  linear_lambda = 0.0,\n  min_gain_to_split = 0,\n  drop_rate_dart = 0.10,\n  max_drop_dart = 50,\n  skip_drop_dart = 0.50,\n  uniform_drop_dart = FALSE,\n  top_rate_goss = FALSE,\n  other_rate_goss = FALSE,\n  monotone_constraints = NULL,\n  monotone_constraints_method = 'advanced',\n  monotone_penalty = 0.0,\n  forcedsplits_filename = NULL, # use for AutoStack option; .json file\n  refit_decay_rate = 0.90,\n  path_smooth = 0.0,\n  \n  # IO Dataset Parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#io-parameters\n  max_bin = 255,\n  min_data_in_bin = 3,\n  data_random_seed = 1,\n  is_enable_sparse = TRUE,\n  enable_bundle = TRUE,\n  use_missing = TRUE,\n  zero_as_missing = FALSE,\n  two_round = FALSE,\n  \n  # Convert Parameters\n  convert_model = NULL,\n  convert_model_language = \"cpp\",\n  \n  # Objective Parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#objective-parameters\n  boost_from_average = TRUE,\n  is_unbalance = FALSE,\n  scale_pos_weight = 1.0,\n  \n  # Metric Parameters (metric is in Core)\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#metric-parameters\n  is_provide_training_metric = TRUE,\n  eval_at = c(1,2,3,4,5),\n  \n  # Network Parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#network-parameters\n  num_machines = 1,\n  \n  # GPU Parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#gpu-parameters\n  gpu_platform_id = -1,\n  gpu_device_id = -1,\n  gpu_use_dp = TRUE,\n  num_gpu = 1)\n\n# Outcome\nModelID = \"Test_Model_1\"\ncolnames \u003c- data.table::fread(file = file.path(getwd(), paste0(ModelID, \"_ColNames.csv\")))\nPreds \u003c- AutoQuant::AutoLightGBMScoring(\n  TargetType = \"classification\",\n  ScoringData = TTestData,\n  ReturnShapValues = FALSE,\n  FeatureColumnNames = colnames[[1L]],\n  IDcols = c(\"IDcol_1\",\"IDcol_2\",\"DateTime\"),\n  EncodingMethod = \"credibility\",\n  FactorLevelsList = NULL,\n  TargetLevels = NULL,\n  ModelObject = NULL,\n  ModelPath = getwd(),\n  ModelID = \"Test_Model_1\",\n  ReturnFeatures = TRUE,\n  TransformNumeric = FALSE,\n  BackTransNumeric = FALSE,\n  TargetColumnName = NULL,\n  TransformationObject = NULL,\n  TransID = NULL,\n  TransPath = NULL,\n  MDP_Impute = TRUE,\n  MDP_CharToFactor = TRUE,\n  MDP_RemoveDates = TRUE,\n  MDP_MissFactor = \"0\",\n  MDP_MissNum = -1)\n```\n\n\u003c/p\u003e\n\u003c/details\u003e\n\n\u003cdetails\u003e\u003csummary\u003eAutoLightGBMMultiClasss() Scoring Example\u003c/summary\u003e\n\u003cp\u003e\n\n```r\n# Refresh data\ndata \u003c- AutoQuant::FakeDataGenerator(\n  Correlation = 0.85,\n  N = 25000L,\n  ID = 2L,\n  AddWeightsColumn = TRUE,\n  ZIP = 0L,\n  AddDate = TRUE,\n  Classification = FALSE,\n  MultiClass = TRUE)\n\n# Partition Data\nSets \u003c- Rodeo::AutoDataPartition(\n  data = data,\n  NumDataSets = 3,\n  Ratios = c(0.7,0.2,0.1),\n  PartitionType = \"random\",\n  StratifyColumnNames = \"Adrian\",\n  TimeColumnName = NULL)\nTTrainData \u003c- Sets$TrainData\nVValidationData \u003c- Sets$ValidationData\nTTestData \u003c- Sets$TestData\nrm(Sets)\n\n# Run function\nTestModel \u003c- AutoQuant::AutoLightGBMMultiClass(\n  \n  # GPU or CPU\n  NThreads = parallel::detectCores(),\n  \n  # Metadata args\n  OutputSelection = c(\"Importances\",\"EvalPlots\",\"EvalMetrics\",\"Score_TrainData\"),\n  model_path = normalizePath(\"./\"),\n  metadata_path = NULL,\n  ModelID = \"Test_Model_1\",\n  NumOfParDepPlots = 3L,\n  EncodingMethod = \"credibility\",\n  ReturnFactorLevels = TRUE,\n  ReturnModelObjects = TRUE,\n  SaveModelObjects = TRUE,\n  SaveInfoToPDF = FALSE,\n  DebugMode = TRUE,\n  \n  # Data args\n  data = TTrainData,\n  TrainOnFull = FALSE,\n  ValidationData = VValidationData,\n  TestData = TTestData,\n  TargetColumnName = \"Adrian\",\n  FeatureColNames = names(TTrainData)[!names(TTrainData) %in% c(\"IDcol_1\",\"IDcol_2\",\"DateTime\",\"Adrian\")],\n  PrimaryDateColumn = NULL,\n  WeightsColumnName = \"Weights\",\n  IDcols = c(\"IDcol_1\",\"IDcol_2\",'DateTime'),\n  CostMatrixWeights = c(1,0,0,1),\n  \n  # Grid parameters\n  GridTune = FALSE,\n  grid_eval_metric = \"microauc\",\n  BaselineComparison = \"default\",\n  MaxModelsInGrid = 10L,\n  MaxRunsWithoutNewWinner = 20L,\n  MaxRunMinutes = 24L*60L,\n  PassInGrid = NULL,\n  \n  # Core parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#core-parameters\n  input_model = NULL, # continue training a model that is stored to file\n  task = \"train\",\n  device_type = \"CPU\",\n  objective = 'multiclass',\n  multi_error_top_k = 1,\n  metric = 'multiclass_logloss',\n  boosting = \"gbdt\",\n  LinearTree = FALSE,\n  Trees = 50L,\n  eta = NULL,\n  num_leaves = 31,\n  deterministic = TRUE,\n  \n  # Learning Parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#learning-control-parameters\n  force_col_wise = FALSE,\n  force_row_wise = FALSE,\n  max_depth = 6,\n  min_data_in_leaf = 20,\n  min_sum_hessian_in_leaf = 0.001,\n  bagging_freq = 1.0,\n  bagging_fraction = 1.0,\n  feature_fraction = 1.0,\n  feature_fraction_bynode = 1.0,\n  lambda_l1 = 0.0,\n  lambda_l2 = 0.0,\n  extra_trees = FALSE,\n  early_stopping_round = 10,\n  first_metric_only = TRUE,\n  max_delta_step = 0.0,\n  linear_lambda = 0.0,\n  min_gain_to_split = 0,\n  drop_rate_dart = 0.10,\n  max_drop_dart = 50,\n  skip_drop_dart = 0.50,\n  uniform_drop_dart = FALSE,\n  top_rate_goss = FALSE,\n  other_rate_goss = FALSE,\n  monotone_constraints = NULL,\n  monotone_constraints_method = 'advanced',\n  monotone_penalty = 0.0,\n  forcedsplits_filename = NULL, # use for AutoStack option; .json file\n  refit_decay_rate = 0.90,\n  path_smooth = 0.0,\n  \n  # IO Dataset Parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#io-parameters\n  max_bin = 255,\n  min_data_in_bin = 3,\n  data_random_seed = 1,\n  is_enable_sparse = TRUE,\n  enable_bundle = TRUE,\n  use_missing = TRUE,\n  zero_as_missing = FALSE,\n  two_round = FALSE,\n  \n  # Convert Parameters\n  convert_model = NULL,\n  convert_model_language = \"cpp\",\n  \n  # Objective Parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#objective-parameters\n  boost_from_average = TRUE,\n  is_unbalance = FALSE,\n  scale_pos_weight = 1.0,\n  \n  # Metric Parameters (metric is in Core)\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#metric-parameters\n  is_provide_training_metric = TRUE,\n  eval_at = c(1,2,3,4,5),\n  \n  # Network Parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#network-parameters\n  num_machines = 1,\n  \n  # GPU Parameters\n  # https://lightgbm.readthedocs.io/en/latest/Parameters.html#gpu-parameters\n  gpu_platform_id = -1,\n  gpu_device_id = -1,\n  gpu_use_dp = TRUE,\n  num_gpu = 1)\n\n# Outcome\nModelID = \"Test_Model_1\"\ncolnames \u003c- data.table::fread(file = file.path(getwd(), paste0(ModelID, \"_ColNames.csv\")))\nPreds \u003c- AutoQuant::AutoLightGBMScoring(\n  TargetType = \"multiclass\",\n  ScoringData = TTestData,\n  ReturnShapValues = FALSE,\n  FeatureColumnNames = colnames[[1L]],\n  IDcols = c(\"IDcol_1\",\"IDcol_2\",\"DateTime\"),\n  EncodingMethod = \"credibility\",\n  FactorLevelsList = NULL,\n  TargetLevels = NULL,\n  ModelObject = NULL,\n  ModelPath = getwd(),\n  ModelID = \"Test_Model_1\",\n  ReturnFeatures = TRUE,\n  TransformNumeric = FALSE,\n  BackTransNumeric = FALSE,\n  TargetColumnName = NULL,\n  TransformationObject = NULL,\n  TransID = NULL,\n  TransPath = NULL,\n  MDP_Impute = TRUE,\n  MDP_CharToFactor = TRUE,\n  MDP_RemoveDates = TRUE,\n  MDP_MissFactor = \"0\",\n  MDP_MissNum = -1)\n```\n\n\u003c/p\u003e\n\u003c/details\u003e\n\n\u003cdetails\u003e\u003csummary\u003eAutoLightGBMHurdleModel() Scoring Example\u003c/summary\u003e\n\u003cp\u003e\n\n```r\n# Classify\nClassify \u003c- TRUE\n\n# Get data\nif(Classify) {\n  data \u003c- AutoQuant::FakeDataGenerator(N = 15000, ZIP = 1)\n} else {\n  data \u003c- AutoQuant::FakeDataGenerator(N = 100000, ZIP = 2)\n}\n\n# Partition Data\nSets \u003c- Rodeo::AutoDataPartition(\n  data = data,\n  NumDataSets = 3,\n  Ratios = c(0.7,0.2,0.1),\n  PartitionType = \"random\",\n  StratifyColumnNames = \"Adrian\",\n  TimeColumnName = NULL)\nTTrainData \u003c- Sets$TrainData\nVValidationData \u003c- Sets$ValidationData\nTTestData \u003c- Sets$TestData\nrm(Sets)\n\n# Run function\nTestModel \u003c- AutoQuant::AutoLightGBMHurdleModel(\n  \n  # Operationalization\n  ModelID = 'ModelTest',\n  SaveModelObjects = FALSE,\n  ReturnModelObjects = TRUE,\n  NThreads = parallel::detectCores(),\n  \n  # Data related args\n  data = TTrainData,\n  ValidationData = VValidationData,\n  PrimaryDateColumn = \"DateTime\",\n  TestData = TTestData,\n  WeightsColumnName = NULL,\n  TrainOnFull = FALSE,\n  Buckets = if(Classify) 0L else c(0,2,3),\n  TargetColumnName = \"Adrian\",\n  FeatureColNames = names(TTrainData)[!names(data) %in% c(\"Adrian\",\"IDcol_1\",\"IDcol_2\",\"IDcol_3\",\"IDcol_4\",\"IDcol_5\",\"DateTime\")],\n  IDcols = c(\"IDcol_1\",\"IDcol_2\",\"IDcol_3\",\"IDcol_4\",\"IDcol_5\",\"DateTime\"),\n  DebugMode = TRUE,\n  \n  # Metadata args\n  EncodingMethod = \"credibility\",\n  Paths = getwd(),\n  MetaDataPaths = NULL,\n  TransformNumericColumns = NULL,\n  Methods = c('Asinh', 'Asin', 'Log', 'LogPlus1', 'Logit'),\n  ClassWeights = c(1,1),\n  SplitRatios = NULL,\n  NumOfParDepPlots = 10L,\n  \n  # Grid tuning setup\n  PassInGrid = NULL,\n  GridTune = FALSE,\n  BaselineComparison = 'default',\n  MaxModelsInGrid = 1L,\n  MaxRunsWithoutNewWinner = 20L,\n  MaxRunMinutes = 60L*60L,\n  \n  # LightGBM parameters\n  task = list('classifier' = 'train', 'regression' = 'train'),\n  device_type = list('classifier' = 'CPU', 'regression' = 'CPU'),\n  objective = if(Classify) list('classifier' = 'binary', 'regression' = 'regression') else list('classifier' = 'multiclass', 'regression' = 'regression'),\n  metric = if(Classify) list('classifier' = 'binary_logloss', 'regression' = 'rmse') else list('classifier' = 'multi_logloss', 'regression' = 'rmse'),\n  boosting = list('classifier' = 'gbdt', 'regression' = 'gbdt'),\n  LinearTree = list('classifier' = FALSE, 'regression' = FALSE),\n  Trees = list('classifier' = 50L, 'regression' = 50L),\n  eta = list('classifier' = NULL, 'regression' = NULL),\n  num_leaves = list('classifier' = 31, 'regression' = 31),\n  deterministic = list('classifier' = TRUE, 'regression' = TRUE),\n  \n  # Learning Parameters\n  force_col_wise = list('classifier' = FALSE, 'regression' = FALSE),\n  force_row_wise = list('classifier' = FALSE, 'regression' = FALSE),\n  max_depth = list('classifier' = NULL, 'regression' = NULL),\n  min_data_in_leaf = list('classifier' = 20, 'regression' = 20),\n  min_sum_hessian_in_leaf = list('classifier' = 0.001, 'regression' = 0.001),\n  bagging_freq = list('classifier' = 0, 'regression' = 0),\n  bagging_fraction = list('classifier' = 1.0, 'regression' = 1.0),\n  feature_fraction = list('classifier' = 1.0, 'regression' = 1.0),\n  feature_fraction_bynode = list('classifier' = 1.0, 'regression' = 1.0),\n  extra_trees = list('classifier' = FALSE, 'regression' = FALSE),\n  early_stopping_round = list('classifier' = 10, 'regression' = 10),\n  first_metric_only = list('classifier' = TRUE, 'regression' = TRUE),\n  max_delta_step = list('classifier' = 0.0, 'regression' = 0.0),\n  lambda_l1 = list('classifier' = 0.0, 'regression' = 0.0),\n  lambda_l2 = list('classifier' = 0.0, 'regression' = 0.0),\n  linear_lambda = list('classifier' = 0.0, 'regression' = 0.0),\n  min_gain_to_split = list('classifier' = 0, 'regression' = 0),\n  drop_rate_dart = list('classifier' = 0.10, 'regression' = 0.10),\n  max_drop_dart = list('classifier' = 50, 'regression' = 50),\n  skip_drop_dart = list('classifier' = 0.50, 'regression' = 0.50),\n  uniform_drop_dart = list('classifier' = FALSE, 'regression' = FALSE),\n  top_rate_goss = list('classifier' = FALSE, 'regression' = FALSE),\n  other_rate_goss = list('classifier' = FALSE, 'regression' = FALSE),\n  monotone_constraints = list('classifier' = NULL, 'regression' = NULL),\n  monotone_constraints_method = list('classifier' = 'advanced', 'regression' = 'advanced'),\n  monotone_penalty = list('classifier' = 0.0, 'regression' = 0.0),\n  forcedsplits_filename = list('classifier' = NULL, 'regression' = NULL),\n  refit_decay_rate = list('classifier' = 0.90, 'regression' = 0.90),\n  path_smooth = list('classifier' = 0.0, 'regression' = 0.0),\n  \n  # IO Dataset Parameters\n  max_bin = list('classifier' = 255, 'regression' = 255),\n  min_data_in_bin = list('classifier' = 3, 'regression' = 3),\n  data_random_seed = list('classifier' = 1, 'regression' = 1),\n  is_enable_sparse = list('classifier' = TRUE, 'regression' = TRUE),\n  enable_bundle = list('classifier' = TRUE, 'regression' = TRUE),\n  use_missing = list('classifier' = TRUE, 'regression' = TRUE),\n  zero_as_missing = list('classifier' = FALSE, 'regression' = FALSE),\n  two_round = list('classifier' = FALSE, 'regression' = FALSE),\n  \n  # Convert Parameters\n  convert_model = list('classifier' = NULL, 'regression' = NULL),\n  convert_model_language = list('classifier' = \"cpp\", 'regression' = \"cpp\"),\n  \n  # Objective Parameters\n  boost_from_average = list('classifier' = TRUE, 'regression' = TRUE),\n  is_unbalance = list('classifier' = FALSE, 'regression' = FALSE),\n  scale_pos_weight = list('classifier' = 1.0, 'regression' = 1.0),\n  \n  # Metric Parameters (metric is in Core)\n  is_provide_training_metric = list('classifier' = TRUE, 'regression' = TRUE),\n  eval_at = list('classifier' = c(1,2,3,4,5), 'regression' = c(1,2,3,4,5)),\n  \n  # Network Parameters\n  num_machines = list('classifier' = 1, 'regression' = 1),\n  \n  # GPU Parameters\n  gpu_platform_id = list('classifier' = -1, 'regression' = -1),\n  gpu_device_id = list('classifier' = -1, 'regression' = -1),\n  gpu_use_dp = list('classifier' = TRUE, 'regression' = TRUE),\n  num_gpu = list('classifier' = 1, 'regression' = 1))\n\n# Remove Target Variable\nTTrainData[, c(\"Target_Buckets\", \"Adrian\") := NULL]\n\n# Score LightGBM Hurdle Model\nOutput \u003c- AutoQuant::AutoLightGBMHurdleModelScoring(\n  TestData = TTrainData,\n  Path = NULL,\n  ModelID = \"ModelTest\",\n  ModelList = TestModel$ModelList,\n  ArgsList = TestModel$ArgsList,\n  Threshold = NULL)\n```\n\n\u003c/p\u003e\n\u003c/details\u003e\n\n\u003c/p\u003e\n\u003c/details\u003e\n\n\n\u003cdetails\u003e\u003csummary\u003eAutoXGBoost__() Examples\u003c/summary\u003e\n\u003cp\u003e\n\n\u003cdetails\u003e\u003csummary\u003eAutoXGBoostRegression() Scoring Example\u003c/summary\u003e\n\u003cp\u003e\n\n```r\n# Refresh data\ndata \u003c- AutoQuant::FakeDataGenerator(\n  Correlation = 0.85,\n  N = 25000L,\n  ID = 2L,\n  FactorCount = 3,\n  AddWeightsColumn = TRUE,\n  ZIP = 0L,\n  AddDate = TRUE,\n  Classification = FALSE,\n  MultiClass = FALSE)\n\n# Copy data\ndata1 \u003c- data.table::copy(data)\n\n# Partition Data\nSets \u003c- Rodeo::AutoDataPartition(\n  data = data1,\n  NumDataSets = 3,\n  Ratios = c(0.7,0.2,0.1),\n  PartitionType = \"random\",\n  StratifyColumnNames = \"Adrian\",\n  TimeColumnName = NULL)\nTTrainData \u003c- Sets$TrainData\nVValidationData \u003c- Sets$ValidationData\nTTestData \u003c- Sets$TestData\nrm(Sets)\n\n# Run function\nTestModel \u003c- AutoQuant::AutoXGBoostRegression(\n  \n  # GPU or CPU\n  TreeMethod = \"hist\",\n  NThreads = parallel::detectCores(),\n  LossFunction = 'reg:squarederror',\n  \n  # Metadata arguments\n  model_path = normalizePath(\"./\"),\n  metadata_path = NULL,\n  ModelID = \"Test_Model_1\",\n  EncodingMethod = \"credibility\",\n  ReturnFactorLevels = TRUE,\n  ReturnModelObjects = TRUE,\n  SaveModelObjects = TRUE,\n  DebugMode = TRUE,\n  \n  # Data arguments\n  data = TTrainData,\n  TrainOnFull = FALSE,\n  ValidationData = VValidationData,\n  TestData = TTestData,\n  TargetColumnName = \"Adrian\",\n  FeatureColNames = names(TTrainData)[!names(TTrainData) %in% c(\"IDcol_1\", \"IDcol_2\",\"DateTime\",\"Adrian\")],\n  WeightsColumnName = \"Weights\",\n  IDcols = c(\"IDcol_1\",\"IDcol_2\",\"DateTime\"),\n  TransformNumericColumns = NULL,\n  Methods = c(\"Asinh\", \"Asin\", \"Log\", \"LogPlus1\", \"Sqrt\", \"Logit\"),\n  \n  # Model evaluation\n  eval_metric = \"rmse\",\n  NumOfParDepPlots = 3L,\n  \n  # Grid tuning arguments\n  PassInGrid = NULL,\n  GridTune = FALSE,\n  grid_eval_metric = \"r2\",\n  BaselineComparison = \"default\",\n  MaxModelsInGrid = 10L,\n  MaxRunsWithoutNewWinner = 20L,\n  MaxRunMinutes = 24L*60L,\n  Verbose = 1L,\n  SaveInfoToPDF = TRUE,\n  \n  # ML args\n  Trees = 50L,\n  eta = 0.05,\n  max_depth = 4L,\n  min_child_weight = 1.0,\n  subsample = 0.55,\n  colsample_bytree = 0.55)\n\n# Score model\nPreds \u003c- AutoQuant::AutoXGBoostScoring(\n  TargetType = \"regression\",\n  ScoringData = data,\n  ReturnShapValues = FALSE,\n  FeatureColumnNames = names(TTrainData)[!names(TTrainData) %in% c(\"IDcol_1\", \"IDcol_2\",\"DateTime\",\"Adrian\")],\n  IDcols = c(\"IDcol_1\",\"IDcol_2\",\"DateTime\"),\n  EncodingMethod = \"credibility\",\n  FactorLevelsList = TestModel$FactorLevelsList,\n  TargetLevels = NULL,\n  ModelObject = TestModel$Model,\n  ModelPath = \"home\",\n  ModelID = \"ModelTest\",\n  ReturnFeatures = TRUE,\n  TransformNumeric = FALSE,\n  BackTransNumeric = FALSE,\n  TargetColumnName = NULL,\n  TransformationObject = NULL,\n  TransID = NULL,\n  TransPath = NULL,\n  MDP_Impute = TRUE,\n  MDP_CharToFactor = TRUE,\n  MDP_RemoveDates = TRUE,\n  MDP_MissFactor = \"0\",\n  MDP_MissNum = -1)\n```\n\n\u003c/p\u003e\n\u003c/details\u003e\n\n\u003cdetails\u003e\u003csummary\u003eAutoXGBoostClassifier() Scoring Example\u003c/summary\u003e\n\u003cp\u003e\n\n```r\n# Refresh data\ndata \u003c- AutoQuant::FakeDataGenerator(\n  Correlation = 0.85,\n  N = 25000L,\n  ID = 2L,\n  AddWeightsColumn = TRUE,\n  ZIP = 0L,\n  AddDate = TRUE,\n  Classification = TRUE,\n  MultiClass = FALSE)\n\n# Partition Data\nSets \u003c- Rodeo::AutoDataPartition(\n  data = data,\n  NumDataSets = 3,\n  Ratios = c(0.7,0.2,0.1),\n  PartitionType = \"random\",\n  StratifyColumnNa","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FAdrianAntico%2FRemixAutoML","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FAdrianAntico%2FRemixAutoML","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FAdrianAntico%2FRemixAutoML/lists"}