Hi. How can i open a file .dat in matlab to make graphs ?

Hi. How can i open a file .dat in matlab to make graphs and operations between arrays?

1 Comment

See if you can open the dat file with a text editor such as notepad. if you can you can use textread and textscan to xtract the info. If so let me know the format and i'll write down the script.

Sign in to comment.

 Accepted Answer

fid = fopen('YourFile.dat', 'r');
That opens the .dat file. Reading the data in it is a different question. There is no fixed format for .dat files: .dat files are any format convenient to the program that generated them. You need to know how your .dat file was generated in order to have a hope of extracting data from it.

More Answers (0)

Categories

Find more on MATLAB in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!