View previous topic
::
View next topic
|
Author |
Message |
ramon fincken Site's programmer
 Get a free globally recognized avatar It's free!
Joined: 03 Aug 2007 Posts: 402 Location: A'dam/Diemen, The Netherlands
|
Posted: Mon Jul 27, 2009 11:47 am Post subject: [matlab][solution] Find first position in 2-dimensional array |
|
|
Consider myo as a 2-dimensional array.
The maximum value is max(max(myo)); => k
max(myo) => will give an array like [0 5 6 0]
Code: | k = (max(max(myo))); answer = find(max(myo) == k,1) |
myo =
[0 5 6 0
1 2 5 4]
max(myo) = k
6
answer will be 3 ( 6 has position 3 in the array ). |
|
Back to top |
|
 |
Google adsense Advertisement
|
Posted: Mon Jul 27, 2009 11:47 am Post subject: [matlab][solution] Find first position in 2-dimensional array |
|
|
Advertisement
|
|
Back to top |
|
 |
GravityForms Advertisement
|
Posted: Mon Jul 27, 2009 11:47 am Post subject: [matlab][solution] Find first position in 2-dimensional array |
|
|
Advertisement
 |
|
Back to top |
|
 |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|
|
|