5.0

5.0 | 2 ratings Rate this file 52 downloads (last 30 days) File Size: 7.12 MB File ID: #18137

Video Tutorial: MATLAB Basics: Varargin and nargin for variable inputs to functions

by Doug Hull

 

27 Dec 2007 (Updated 27 Dec 2007)

Code covered by BSD License  

Three minute video discusses how to use varargin and nargin to get a variable number of inputs.

Download Now | Watch this File

File Information
Description

Three minute video shows how you can use varargin and nargin to allow for a variable number of inputs into a function. This is often useful when you want to have default values for inputs if the user does not specified them.
See more videos without downloading here:
http://blogs.mathworks.com/pick/category/video

MATLAB release MATLAB 7.5 (R2007b)
Zip File Content  
HTML Files Video from http://blogs.mathworks.com/pick
Other Files
65 Advanced Varargin.css,
65 Advanced Varargin.flv,
mCode/main.m,
65 Advanced Varargin.js,
65 Advanced Varargin_config.xml,
65 Advanced Varargin_controller.swf,
65 Advanced Varargin_iPod.m4v,
65 Advanced Varargin_nofp_bg.gif,
65 Advanced Varargin_preload.swf,
Additional-embed.js,
ProductionInfo.xml,
swfobject.js,
images/bottom_center.jpg,
images/bottom_center_left.jpg,
images/bottom_left.jpg,
images/bottom_right.jpg,
images/vid_bkgd.gif,
images/dl_bkgd.gif,
images/dl_icon.gif,
images/dl_icon_bkgd.gif,
images/dl_icon_bkgd_over.gif,
images/dl_row_bkgd.gif,
images/play_bttn_bkgd.gif,
images/play_icon.gif,
images/spacer.gif,
images/top_center.gif,
images/top_center.jpg,
images/top_center_clr.gif,
images/top_left_corner.jpg,
images/top_right_corner.jpg,
images/curain_bkgd.gif
Tags for This File  
Everyone's Tags
Tags I've Applied
Add New Tags Please login to tag files.
Comments and Ratings (2)
09 Jan 2008 jiangming zhang

it is stimulating

06 Mar 2009 Jaime Ramos

Just what I needed to get me going at 2:30am ! =)
It's all cut to the chase and no fluff, great job Doug

Jaime

Please login to add a comment or rating.
Tag Activity for this File
Tag Applied By Date/Time
video Doug Hull 22 Oct 2008 09:40:38
tutorial Doug Hull 22 Oct 2008 09:40:38
varargin nargin Doug Hull 22 Oct 2008 09:40:38
input Doug Hull 22 Oct 2008 09:40:38
defaults Doug Hull 22 Oct 2008 09:40:38
varargout Doug Hull 22 Oct 2008 09:40:38
varargin nargin Daniel 28 Sep 2009 17:42:13
 

MATLAB Central Terms of Use

NOTICE: Any content you submit to MATLAB Central, including personal information, is not subject to the protections which may be afforded information collected under other sections of The MathWorks, Inc. Web site. You are entirely responsible for all content that you upload, post, e-mail, transmit or otherwise make available via MATLAB Central. The MathWorks does not control the content posted by visitors to MATLAB Central and, does not guarantee the accuracy, integrity, or quality of such content. Under no circumstances will The MathWorks be liable in any way for any content not authored by The MathWorks, or any loss or damage of any kind incurred as a result of the use of any content posted, e-mailed, transmitted or otherwise made available via MATLAB Central. Read the complete Terms prior to use.

Contact us at files@mathworks.com