Not enough input arguments

function fout=ff(pop)
fout=pop(:,1).^2+pop(:,2).*pop(:,3)+pop(:,4);
end
Where pop is an known 100*4 matrix

回答(1 个)

function fout=ff(pop)
fout=pop(:,1).^2+pop(:,2).*pop(:,3)+pop(:,4);
end
>> pop = rand(100,4);
>> ff(pop)
This works perfectly fine for me.
How are you calling your function?

类别

帮助中心File Exchange 中查找有关 Startup and Shutdown 的更多信息

提问:

2013-1-17

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by