Notes, convert 3D matrix to patched 2D matrix

I was trying to visualize a 3D matrix’s sparsity. The spy function in matlab doesn’t work with 3D matrix. As a result, I had to try to find a way to flatten the 3D matrix by patching the 2D slices together. I found the following post very useful, especially the permutate answer.

http://www.mathworks.com/matlabcentral/answers/32011-how-to-save-a-graph-in-jpg-or-any-other-image-format

Advertisements
This entry was posted in matlab. Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s