MATLAB: How to convert num2str for fprintf(fid, )

fprintfstr2num

at the first i convert my string to number
x(indexi,indexj)=str2num(string);
indexj=indexj+1 ;
but at the end i want to use fprintf and convert num to string num2str again to print it in text file
fprintf (fid , )

Best Answer

'%f' or '%g' or '%e'