Usingsscanf will be faster than usingstr2double in a cell array:
C = {'0.001','0.34'; '89','34'; '0.898','988'};
cellfun(@(s)sscanf(s,'%f'), C)
This defines ananonymous function , which is then called bycellfun for each string in the cell arrayC.
EDIT: Based on Guillaume's Answer and my own tests, the fastest conversion that I could achieve (I don't havestrjoin) was using array preallocation and a loop, like this:
Best Answer