octaveでvector中の最小値、最小値のindexの求め方
vector = [3; 2; 5; 1];
minValue = min(vector)
% minValue = 1
minIdx = find(vector == min(vector))
% minIdx = 4
Go to list of users who liked
More than 5 years have passed since last update.
octaveでvector中の最小値、最小値のindexの求め方
vector = [3; 2; 5; 1];
minValue = min(vector)
% minValue = 1
minIdx = find(vector == min(vector))
% minIdx = 4
Register as a new user and use Qiita more conveniently
Go to list of users who liked