function E(x)
% Nested in D
disp(x)
end
end
end
The easiest way to extend the scope of a nested function is to create a function handle and return it
as an output argument, as shown in “Using Handles to Store Function Parameters” on page 20-29.
Only functions that can call a nested function can create a handle to it.
See Also
More About
•
“Resolve Error: Attempt to Add Variable to a Static Workspace.” on page 20-33
•
“Create Function Handle” on page 13-2
•
“Checking Number of Arguments in Nested Functions” on page 21-8
•
“Types of Functions” on page 20-17
20 Function Basics
20-32
Précédent

- 740/1450

Suivant