matlab/matlab-agentic-toolkit / skills-catalog/ai-and-statistics/matlab-classify-tabular-data
matlab-classify-tabular-data
UnverifiedUse this skill to classify tabular data end-to-end in MATLAB — load a dataset, prepare and clean it, select promising classifiers, train them, and compare accuracies with cross-validation, holdout, or hyperparameter optimization plus statistical tests. TRIGGER when: user asks to classify tabular data, pick classifiers for a dataset, compare classifier accuracy, run cross-validation or a holdout evaluation, or find the best model with statistical uncertainty. DO NOT TRIGGER when: user has non-tabular inputs (images, sequences, time series), wants a regression model, is training a specific neural network architecture (use matlab-train-network), or wants cost-sensitive learning or an arbitrary class-prior vector (this skill only supports the built-in uniform-prior toggle for imbalanced data).
scripts/model_catalog/imbalanced_boosting.m
View on GitHub% imbalanced_boosting.m
%
% Overrides the "Boosted ensembles" model list produced by branches 1,
% 2, and 4 when isImbalanced. Applied AFTER base branch selection.
%
% Contract: a *script* invoked via
%
% run(fullfile(skillPath, 'scripts', 'model_catalog', 'imbalanced_boosting.m'))
%
% populates IMBALANCED_BOOSTING_MODELS in the caller's workspace. The
% caller then substitutes these recipes for the branch's built-in
% boosting recipes (LogitBoost, RoughAdaBoost, FineAdaBoost).
%
% RUSBoost inclusion is gated on smallestClassSize — RUS's
% undersampling produces unstable learners with too few minority
% observations.
% model_recipe() lives alongside this file in scripts/model_catalog/.
% See classifier_branches.m for the reason the catalog files stay together.
IB_HERE = fileparts(mfilename('fullpath'));
run(fullfile(IB_HERE, 'classifier_thresholds.m')); % populates THRESHOLDS
IB_RUSBOOST_MIN = THRESHOLDS.rusboost_smallest_class;
IMBALANCED_BOOSTING_MODELS = [ ...
... % RUSBoost family (only when smallest class large enough).
model_recipe('RoughRUSBoost', 'fitcensemble', ...
struct('Method','RUSBoost','NumLearningCycles',30,'LearnRate',0.1), ...
'InnerLearnerFn', 'templateTree', ...
'InnerLearnerArgs', struct('MaxNumSplits',10), ...
'Interp', {{'low'}}, ...
'Condition', @(f) f.smallestClassSize >= IB_RUSBOOST_MIN) ...
model_recipe('FineRUSBoost', 'fitcensemble', ...
struct('Method','RUSBoost','NumLearningCycles',30,'LearnRate',0.1), ...
'InnerLearnerFn', 'templateTree', ...
'InnerLearnerArgs', struct('MaxNumSplits', @(f) 5*f.nClasses*(f.nClasses-1)), ...
'Interp', {{'low'}}, ...
'Condition', @(f) f.smallestClassSize >= IB_RUSBOOST_MIN && ~f.isBinary) ...
...
... % Standard boosting (same as balanced case; included so a
... % head-to-head with RUSBoost is possible).
model_recipe('LogitBoost', 'fitcensemble', ...
struct('Method','LogitBoost','NumLearningCycles',30,'LearnRate',0.1), ...
'InnerLearnerFn', 'templateTree', ...
'InnerLearnerArgs', struct('MaxNumSplits',10), ...
'Interp', {{'low'}}, ...
'BinaryOnly', true) ...
model_recipe('RoughAdaBoost', 'fitcensemble', ...
struct('Method','AdaBoostM2','NumLearningCycles',30,'LearnRate',0.1), ...
'InnerLearnerFn', 'templateTree', ...
'InnerLearnerArgs', struct('MaxNumSplits',10), ...
'Interp', {{'low'}}, ...
'Condition', @(f) ~f.isBinary) ...
model_recipe('FineAdaBoost', 'fitcensemble', ...
struct('Method','AdaBoostM2','NumLearningCycles',30,'LearnRate',0.1), ...
'InnerLearnerFn', 'templateTree', ...
'InnerLearnerArgs', struct('MaxNumSplits', @(f) 5*f.nClasses*(f.nClasses-1)), ...
'Interp', {{'low'}}, ...
'Condition', @(f) ~f.isBinary) ...
];
clear IB_HERE IB_RUSBOOST_MIN
% Copyright 2026 The MathWorks, Inc.
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| finishing-a-development-branchobra/superpowersUse when implementation is complete, all tests pass, and you need to decide how to integrate the work | Stars: 319k | Updated | Claude CodeCodex | Verified | Install |
| systematic-debuggingobra/superpowersUse when encountering any bug, test failure, or unexpected behavior, before proposing fixes | Stars: 319k | Updated | Claude CodeCodex | Verified | Install |
| test-driven-developmentobra/superpowersUse when implementing any feature or bugfix, before writing implementation code | Stars: 319k | Updated | Claude CodeCodex | Verified | Install |
| skill-creatoranthropics/skillsCreate new skills, modify and improve existing skills, and measure skill performance. Use when users want to create a skill from scratch, edit, or optimize an existing skill, run evals to test a skill, benchmark skill performance with variance analysis, or optimize a skill's description for better triggering accuracy. | Stars: 196k | Updated | Claude CodeCodex | Verified | Install |