MATLAB爱好者论坛-LabFans.com

MATLAB爱好者论坛-LabFans.com (https://www.labfans.com/bbs/index.php)
-   资料存档 (https://www.labfans.com/bbs/forumdisplay.php?f=72)
-   -   如何从MATLAB中的函数捕获输出? (https://www.labfans.com/bbs/showthread.php?t=23476)

poster 2019-12-10 20:41

如何从MATLAB中的函数捕获输出?
 
我有一个简单的功能

function increase(percent, number) low = number - number*percent; end 我想返回低电平,因此可以将其用作另一个函数的参数

mitoGen(asp, arg, increase(0.2, 234), glu) 有没有办法做到这一点?



[B]回答:[/B]

因此:

function low = increase(percent, number) low = number - number*percent; end 您还可以通过在等号左侧添加多个内容来返回多个项目:

function [out1, out2] = foo(bar, baz)

[url=https://stackoverflow.com/questions/2908753]更多&回答...[/url]


所有时间均为北京时间。现在的时间是 01:15

Powered by vBulletin
版权所有 ©2000 - 2025,Jelsoft Enterprises Ltd.