Performance metrics of an algorithm
2 次查看(过去 30 天)
显示 更早的评论
I have a desired vector u=[1 2 pi/4.1 pi/4]. I am using a metaheuristic algorithm BOA (Butterfly Optimization Algorithm). I estimate 100 vectors of the same size as u. I determine Error between u and each estimated vector. i.e. E1=u-Est1, E2=u-Est2, ---------E100=u-Est100. So I get 100 error vectors of same size as u.
The nature of 1st two elements in each vector is same i.e. both are amplitudes, and nature of 3rd and 4th elements are same,i.e both are angles.
My question is what performance metrics can I use for this on the basis of which I can comment on the performance of this algorithm. i.e. I am able to say that the algorithm is better because it estimated my vector approximately like my desired etc.
0 个评论
回答(1 个)
JESUS DAVID ARIZA ROYETH
2019-11-6
you can find the quadratic error of each parameter and then multiply it by a constant value that you consider to give greater or lesser importance to the error of said parameter
Here is a very useful example :
u=[1 2 pi/4.1 pi/4];%your desired value
e=2*randn(100,4);%your population 100x4 in this case random
err=sum([5 5 1 1].*(u-e).^2,2) % error for each vector (100x1)
in this example of 1st two elements are more important and that is why they are multiplied by 5
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Multidimensional Arrays 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!