MATLAB: I have a string with the form of that of what you would write to initialize a matrix; how to make the string a matrix


Title says it all. ex: myStr = [1,2,3, 5:7]; how do I make it so myArray = [1,2,3,5,6,7].
Thanks in advance, George

Best Answer

  • myStr = '[1,2,3, 5:7]'