MATLAB: Put the coordinates from a string to a array

arraycoordinateMATLABstringtransfertxml

I have to put the coordinates that come from a string in an array
value = 2498536 1117123 412 2498543 1117124 412 2498543 1117124 414 2498536 1117123 414 2498536 1117123 412
I need to extract the value and put them as number in a array. I would like to put them three by three like this
2498536 1117123 412
2498543 1117124 412
2498543 1117124 414
2498536 1117123 414
2498536 1117123 412
What would be the easier way to do this ?
Thanks for helping

Best Answer

val = '2498536 1117123 412 2498543 1117124 412 2498543 1117124 414 2498536 1117123 414 2498536 1117123 412' ;
iwant = reshape(str2num(val),3,[])';