29January08

29January08 - Assignments Read Chapter 4 HW 1 Due Print off MatLab Reference sheet To import data-go to file and select data file Opens an import

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
1/29/08 Assignments: Read Chapter 4 HW 1 Due 2/7/08 Print off MatLab Reference sheet. To import data-go to file and select data file. Opens an import wizard, telling us how it reads the data. Script Files -Not Really Programs. -No input or out put of parameters. -Script File variables are part of the workspace. -Use them for tasks that never change. -Use for homework -Beware of the side effects resulting form script files -unexpected changes in your work space can occur Function M- Files -are sub programs -can do i/o w/parameters. -variables are local and won’t change work space. -Functions can call other functions. Syntax -Function[outargs]=functionname(inargs) out args are optional. Separated lists of variable names. [ ] optional not need if function returns a scalar. In args: comma separated list of variables names in 9 0 Functions with no inargs are legal. Input Easiest way is to use the input command “input” N=input(‘prompt’) -displays prompt, gets input, stores in N. n=input(‘prompt’,’s’)
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 2
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 03/31/2008 for the course MATH 340 taught by Professor Meyer during the Spring '08 term at Wisconsin.

Page1 / 3

29January08 - Assignments Read Chapter 4 HW 1 Due Print off MatLab Reference sheet To import data-go to file and select data file Opens an import

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online