Monday, November 29, 2010

How to put Excel data into Matlab and retain the 'cell' structure

1. Make your cell structure by using curly brackets:
A={1}
2. Copy the excel data to the clipboard
3. Then open up "A" and right click on the top left cell-- choose 'paste excel data'
4. Save your variable A
5. Use it in Matlab:
B = cell2mat(A(row # to start on : row # to end on , column # );

1 comment:

  1. Leslie, you are amazing!

    http://www.mathworks.com/videos/matlab/importing-data-from-files.html?video_title

    ReplyDelete