I'm trying to develop a C++ k-means program that will be reading text files. The problem is that the text files are not uniform.
For example, data1.txt looks like
0.1
3.0
0.7
0.5
0.2
1.5
1.6
and data3.txt looks like
33 37 53
35 36 52
34 37 53
35 37 51
34 38 52
33 38 51
33 39 52
33 37 52
34 37 52
34 39 52
I'm thinking I should store the data in a vector somehow. What's the best way to develop this without forcing the user to tell the program how many dimensions each entry in the text file has? I want the user to call the program like
program data_.txt #
Where data_.txt = any text file and # = the number of clusters