function - how to find min and max of float number in matlab -


the min , max functions in matlab work on integer values. how can find min , max of double vector?

a = [2.1 3.4 5.6 7.6] min(a) 

returns me:

subscript indices must either real positive integers or logicals.

you've assigned min variable name array somewhere in code.

when call min(a), matlab trying grab indices [2.1,3.4,5.6,7.6] array min. fix problem, call variable else.

edit: , if you're running outside of function, clear min , max, @acorbe points out.


Comments

Popular posts from this blog

Change php variable from jquery value using ajax (same page) -

Pull out data related to my apps from Android Play Store and iOS App Store -

How can I fetch data from a web server in an android application? -