Extracts battery features in MATLAB from voltage, current, and temperature measurements for cycling tests, HPPC/pulse tests, EIS impedance sweeps, or single charge/discharge segments. Outputs a feature table for SOH, RUL, degradation, internal resistance, or impedance analysis.
Ships in control-systems. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them; scripts run unread.
Router for MATLAB's Predictive Maintenance Toolbox battery feature extraction functions. Detailed workflows live in references/*.md — load only the file that matches the inspected data type.
Trigger on the domain questions asked about battery voltage / current / temperature measurements — from bench cycler / HPPC / EIS tests or from in-field / in-use operational data logged by a BMS or captured during a drive or charge event. The skill produces the feature table that feeds each question's downstream analysis. Concretely:
batteryMeasurementFeatures, which works stats-only when no cycle/time structure is present.).res, Neware .nda, Maccor, BioLogic → MATLAB table).This skill covers the 7 PMT battery feature extraction functions. These functions work natively with MATLAB tables and vectors, handle segmentation and peak detection internally, and are performance-optimized. Prefer these PMT functions over manual feature computation (e.g., hand-coded cumtrapz loops, manual peak finding). Override only if the user explicitly requests otherwise.
The Predictive Maintenance Toolbox provides 7 public functions for battery feature extraction, organized by the kind of measurement they consume:
Battery Data
│
┌────────────────┬─────────────┴────────┬────────────────────┐
│ │ │ │
Multi-cycle Single measured Pulse tests EIS tests
cycling test segment (HPPC / GITT) (impedance)
│ (bench or in-field) │ │
▼ │ ▼ ▼
batteryTest- │ batteryPulseFeatures batteryEISFeatures
DataParser │ │ │
+ │ ▼ ▼
batteryTest- │ Pulse feature EIS feature
FeatureExtractor │ table table
│ │
▼ ├── batteryMeasurementFeatures → Measurement feature table
Full-pipeline │
feature table ├── batteryDifferentialCurves → IC / DV / DT curves
│
└── batteryDifferentialCurveFeatures → Curve peak feature table
The single measured segment branch is the in-field / operational path: its functions take raw V / I / T / t from one charge or discharge segment and need no multi-cycle test structure, so they serve BMS-logged or drive/charge-event data as well as a segment pulled from a bench test.
| Function | Input | Output | Use When | Available From |
|---|---|---|---|---|
batteryTestDataParser | Raw cycling table | Parser object (segmented data) | Multi-cycle data needing segmentation | R2024b |
batteryTestFeatureExtractor | Options | Extractor object | Full pipeline: parser → all cycling features | R2024b |
batteryMeasurementFeatures | V, I, T, t vectors | Statistical + cumulative feature table | Any single-phase segment (partial or full charge/discharge) | R2026a |
batteryDifferentialCurves | V, I, T, t vectors | dQ/dV, dV/dQ, dT/dV tables | Constant-current segment only (CC charge or CC discharge) | R2026a |
batteryDifferentialCurveFeatures | Curve + x-axis | Peak feature table | Extracting features from differential curves | R2026a |
batteryPulseFeatures | V, I, t (or table) | Pulse feature table + pulse data | HPPC/pulse test resistance features | R2026b |
batteryEISFeatures | Zr, Zi, F vectors | EIS feature table | Impedance spectroscopy analysis | R2026b |
Step 1 — inspect the data shape. Load the file directly from the exact path the user gave, resolved against the current working folder. Do not recursively search temp, home, or system directories to locate it — a recursive dir(..., '**', ...) over such a tree can stall for over a minute. Then read the file and answer two questions:
Capacity, SOH, CV_hold_duration)?CellID / Cell / SerialNumber column identifying multiple cells in the same file?Step 2 — route by shape:
| Data shape inspected | Route |
|---|---|
| Raw per-sample multi-cycle cycling table with cycle and step index columns (one cell, or multi-cell — see note below) | references/cycling-pipeline.md |
| Raw per-sample cycling table with step index but no cycle index — either multiple cycles the parser can synthesize a cycle index for, or a single full charge-discharge cycle (see reference for the multi- vs single-cycle rule) | references/cycling-pipeline.md |
| Raw per-sample single-phase cycling segment (partial charge, one discharge, CC segment) with no cycle index and no full charge-discharge boundary | references/individual-cycling-functions.md |
| Raw short current pulses separated by rest periods (HPPC / GITT) | references/pulse-features.md |
Raw impedance sweep with Frequency, Zreal, Zimag | references/eis-features.md |
Already-aggregated per-cell / per-cycle summary — one row per (cell, cycle) with pre-computed Capacity, SOH, CV_hold_duration, RPT_capacity, temperature summaries, etc. (no per-sample V/I/t traces) | No reference loads. See § Data Is Already Aggregated below. |
Additionally, when tuning Tolerance, WindowSize, IC/DV/DT smoothing, or diagnosing "not CC data" errors | Also load references/parameter-tuning.md |
Multi-battery-cell data. When the data covers more than one battery cell, see the loaded reference's § Preprocessing: Data Layout for detection and combine/iterate rules, and § Postprocessing: Feature Table Organization for the featuresPerCell{k} output convention.
If each row is already a per-cycle or per-cell summary (e.g., a CSV with columns CellID, Cycle, Capacity_Ah, SOH, CV_hold_s, Temp_max_C), the PMT battery* functions covered by this skill have nothing to add — they compute those very features from raw traces, and you already have them. Tell the user this, then handle the cell-ranking / degradation-comparison task with plain table operations:
Capacity vs Cycle per CellID, sort ascending.CV_hold_s, temperature statistics, or resistance summaries per cell.tiledlayout: capacity-vs-cycle families, SOH trajectories, CV-hold growth.This is standard MATLAB table wrangling — no PMT function is required. If a downstream skill fits better (e.g. matlab-analyze-data for the ranking workflow), route there instead of loading a reference from this skill.
Application × data shape. When the user names an application (SOH, RUL, Fast Charging, Cell Screening) that could be served by multiple data types, still route by inspected shape first — application alone doesn't pick a workflow. Then read the matching reference's "Feature Selection for Common Applications" section for the recipe.
Every reference in this skill follows the same phase template. Load the matching reference for the phase-by-phase details; the skeleton is:
| # | Phase | What it does |
|---|---|---|
| 1 | Identify inputs | Map data columns to the function's parameters. Workflow-specific vocabulary table lives at the top of each reference. General rules (vocabulary-first, datetime > numeric, unit conversion) below. |
| 2 | Data layout | Detect single-file vs multi-file, single-cell vs multi-cell, single-sweep vs multi-sweep; combine or split accordingly. |
| 3 | Call functions | Issue the primary computation call(s). |
| 4 | Verify results | Cross-check outputs against independent evidence. Cycling uses verifySegmentation + checkCyclingProtocol; individual-cycling uses verifySingleSegment. Pulse and EIS skip this phase — no verifier helper exists. |
| 5 | Tune parameters | Only if Phase 4 flagged an issue (or the caller reports symptoms of a wrong setting). Sweep tuning parameters and re-call. |
| 6 | Postprocess / organize | Attach tag columns (CellID, ExperimentIndex), keep per-cell tables in a cell array, etc. |
| 7 | Report + next steps | Present the feature table with the key-decisions summary and the Next Steps offer (§ Stop After Extraction rule below). |
Reference-to-phase map:
| Reference | Phases | Verify helper | Tuning reference |
|---|---|---|---|
cycling-pipeline.md (+ cycling/*.md on demand) | 1-7 | verifySegmentation or verifyAgainstSchedule, + checkCyclingProtocol | cycling/tolerance-tuning.md or cycling/schedule-verification.md; parameter-tuning.md (IC/DV/DT smoothing) |
individual-cycling-functions.md | 1-7 | verifySingleSegment | parameter-tuning.md (IC/DV/DT smoothing, NoiseTolerance) |
pulse-features.md | 1-3, 5-7 (no Verify) | — | inline (ValidPulseDurationRange, MinCurrentChange) |
eis-features.md | 1-3, 5-7 (no Verify) | — | inline (NumArcs, multi-sweep splitting) |
Cross-cutting rules that apply to every workflow — do not skip regardless of which reference you loaded.
Do not stop and ask before every extraction. Most decisions have a deterministic rule — apply it, extract, and report what you did so the user can correct it. Only stop when a decision is genuinely ambiguous and guessing it wrong would fail silently (plausible-but-wrong features). The rule applies to every workflow — cycling pipeline, individual cycling functions, pulse, and EIS.
STOP and ask the user first — but only when one of these is true:
General (all workflows):
Cycling pipeline only:
checkCyclingProtocol finds neither phase consistent — no phase can be recommended.Otherwise PROCEED, then REPORT. Apply the deterministic rules — datetime/duration beats numeric time; set DT=true iff temperature is present; set CC=true whenever IC/DV/DT is requested; for cycling, use checkCyclingProtocol's RecommendedPhase — write and run the extraction, then present in a single after-extraction turn:
CyclingPhase and its consistency reason; pulse: pulse-detection thresholds if adjusted; EIS: frequency range or sweep selected if the file had multiple,Close the report with an explicit undo invitation, e.g. "If any mapping or the phase choice looks wrong, tell me and I'll re-run." This preserves the safety net without a blocking question.
Once the feature table is extracted and displayed, stop and present available next steps to the user. Do not autonomously proceed to visualization, feature ranking, or script saving. The stopping turn must have three parts:
verifySegmentation returned TuningRecommended, checkCyclingProtocol reported anomalous cycles, or pulse/EIS detection returned empty/failed. State the flag and the concrete re-run it implies ("3 cycles segmented inconsistently — I can re-run with a tighter Tolerance, or exclude them").
- Visualize: plots appropriate to the workflow (see the loaded reference's Phase 7 Visualize hints; cycling loads
references/cycling/postprocess.md)- Rank features: identify most discriminative features for your analysis goal
- Export: save the feature table to a .mat or .csv file
- Refine: adjust feature categories, phase, or smoothing parameters
Only execute a next step when the user explicitly requests it. This applies even if the original prompt contains phrasing like "show me" or "plot" — extract first, present the table with the key decisions, then offer to visualize.
Workflow-specific column vocabularies live in the loaded reference's Phase 1 (Identify inputs). The rules below apply regardless of which vocabulary you're consulting.
Vocabulary first — try common vendor names before declaring a column missing. The 4 mainstream cyclers (Arbin, Neware, Maccor, BioLogic) and typical EIS/potentiostat exports each use different conventions. Match case-insensitively; strip units suffixes (_V, _A, /mA, /V, /Hz, /Ohm); a match on any name in the reference's Phase 1 vocabulary is sufficient — no need to stop-and-ask.
Unit conversion when the column name carries units. If the current column is I/mA (milliamps), convert to Amps before passing to the function (data.I_A = data.("I/mA") / 1000); same for mV → V. Report the conversion in the after-extraction summary.
datetime/duration type and another is numeric seconds, the datetime column wins — this is a rule, not a judgment call. Apply it and report it rather than asking. Note the alternative you considered in the after-extraction report (e.g., "I found both Test_Time (numeric) and DateTime (datetime type) — used DateTime as it is a proper datetime column").When data is a raw numeric matrix (no column names), infer column roles from value characteristics, then confirm with the user before proceeding:
Present the inferred mapping and ask the user to confirm. Example:
Your data is a 641×3 matrix with no column names. Based on value ranges:
- Column 1: spans 0.05 to 10000 (likely Frequency)
- Column 2: all positive, range 13–22 (likely Zreal)
- Column 3: range -14 to 6, mixed sign (likely Zimag)
Does this mapping look correct?
Only two pitfalls are truly cross-cutting. Workflow-specific pitfalls (time format, phase mixing, DT requirements, feature-count overfitting, CC data requirements, EIS sign conventions, pulse-detection thresholds, etc.) live in the loaded reference's own § Pitfalls section — consult it before extracting.
cumtrapz, findpeaks, or manual segmentation loops.Copyright 2026 The MathWorks, Inc.
manifest.yaml (opens in a new tab)references/cycling-pipeline.md (opens in a new tab)references/cycling/feature-selection.md (opens in a new tab)references/cycling/multi-cell.md (opens in a new tab)references/cycling/postprocess.md (opens in a new tab)references/cycling/schedule-verification.md (opens in a new tab)references/cycling/tolerance-tuning.md (opens in a new tab)references/eis-features.md (opens in a new tab)references/individual-cycling-functions.md (opens in a new tab)references/parameter-tuning.md (opens in a new tab)references/pulse-features.md (opens in a new tab)scripts/checkCyclingProtocol.m (opens in a new tab)scripts/sweepScheduleAndReport.m (opens in a new tab)scripts/verifyAgainstSchedule.m (opens in a new tab)scripts/verifySegmentation.m (opens in a new tab)scripts/verifySingleSegment.m (opens in a new tab)What SKILL.md sets; muted values are Claude Code's defaults
/control-systems:matlab-extract-battery-featuresfrom control-systems
npx claudepluginhub matlab/matlab-agentic-toolkit --plugin control-systems3 skills in this plugin
/matlab-extract-rotating-machinery-featuresExtract features from signals collected on rotating machinery components, including motors, pumps, fans, gears, bearings, and shafts. Signals can include vibration, electrical, or environmental sensor measurements. Use when developing and deploying condition monitoring and fault detection applications for rotating machinery, including industrial machines, electrical vehicles, internal combustion engines, turbines, and drive trains./matlab-identify-linear-systemIdentify a linear dynamic model from input-output or time-series data using MATLAB System Identification Toolbox. Use when estimating transfer function, state-space, ARX, ARMAX, BJ, OE polynomial or process models from measurement data.
Other plugins' skills for the same job