How to create a verctor in matlab using data recorded in a text document?

1 reply · 3K views · last reply
da_coolest
Messages
15
Reaction score
0
There is a text document with data separated by the "," sign.

such as 58.5698, 75.2495, 57.1548...

I want to createa vector called Y in MATLAB using these datas. there are 50 values.
i opened the file with the fopen command.
And then tried with the fgetl command. but when I use the "Y(1)" command to get the first value, it produces the number 5 instead of the 58.5698.

Thanks in advance.