I have the following content in a text file
1 2 3.45 4
2 2 3.43 4
3 2 3.23 4
4 2 3.46 4
5 2 3.345 4
6 2 3.4567 4
I'm trying to read the input in the following manner
m = 6n = 4fileid = fopen(f,'r');content = fscanf(fileid,'%f', [m n]);
This doesn't return the above data as m x n .
May I know what's the right way to read this data?
Best Answer