Default arguments
Version 1.6.0.0 (1.24 KB) by
Bas-Jan
Set default values for optional function input.
Set default arguments for use in function, without having to code the switch-case blocks. Code is quite trivial, but it saves me some time coding.
Cite As
Bas-Jan (2026). Default arguments (https://www.mathworks.com/matlabcentral/fileexchange/41497-default-arguments), MATLAB Central File Exchange. Retrieved .
MATLAB Release Compatibility
Created with
R2013a
Compatible with any release
Platform Compatibility
Windows macOS LinuxCategories
- Simulink > Block and Blockset Authoring > Author Block Algorithms > Author Blocks Using MATLAB > Author Blocks Using MATLAB System Objects > Customize System Objects for Simulink >
Find more on Customize System Objects for Simulink in Help Center and MATLAB Answers
Tags
Discover Live Editor
Create scripts with code, output, and formatted text in a single executable document.
