MATLAB: Str2num conversion for vectors

MATLABworkspace

Hello! About str2num conversion..
This is what I found in the Matlab help: A = str2num('uint16(500)') A = 500
class(A)
ans =
uint16
I want to do this for a vector like: A = str2num('uint16(500 300 100)') The result will be: A= [];
How can I solve this problem?
Thanks!

Best Answer

A = str2num('uint16([500 300 100])')