The argument of maximum means the index at which the vector/function values is maximized.
Example
>> a = [3 2 1 -2 7]
a =
3 2 1 -2 7
>> [max_value, argmax] = max(a)
max_value =
7
argmax =
5
>> [min_value, argmin] = min(a)
min_value =
-2
argmin =
4
>>
References:
Arg max (Wikipedia)
how do i find argmax? (MathWorks)
Information about Electrical, Electronic, Communication and Computer Engineering 電機、電子、通訊、電腦資訊工程的學習筆記
相關資訊~生醫工程:StudyBME
聽力科技相關資訊:電子耳資訊小站
iOS程式語言:Study Swift
樹莓派和Python:Study Raspberry Pi
2018/09/04
2018/09/03
Matlab: feval() - Call functions with the function name as a string input
To call any Matlab function, use feval() with the function nameas the first input string and the parameters of the function as the other remaining input arguments.
For example, for sayHello.m:
function sayHello(name)
fprintf('Hello %s!\n',name);
Results of the command line with fevel():
>> sayHello('Matlab')
Hello Matlab!
>> feval('sayHello','World')
Hello World!
Reference:
feval() - Evaluation function (MathWorks)
For example, for sayHello.m:
function sayHello(name)
fprintf('Hello %s!\n',name);
Results of the command line with fevel():
>> sayHello('Matlab')
Hello Matlab!
>> feval('sayHello','World')
Hello World!
Reference:
feval() - Evaluation function (MathWorks)
訂閱:
文章 (Atom)