File Exchange

image thumbnail

Matrix Visualization with Matlab

version 1.0.2 (2.1 KB) by Hristo Zhivomirov
Visualization of numeric matrices with up to three dimensions (rows, columns, pages).


Updated 09 Apr 2020

View Version History

View License

The present code is a Matlab function that produces a view of a numeric matrix, where each matrix element is shown with its value and coded with color. The columns’ and rows’ numbers are placed on the x- and y-axis, respectively. The exact location and value of a given element on the matrix plot could be observed using the Data Cursor.

A few examples are given in order to clarify the usage of the function. For convenience, the input and output arguments are given in the beginning of the function.

Cite As

Hristo Zhivomirov (2021). Matrix Visualization with Matlab (, MATLAB Central File Exchange. Retrieved .

Comments and Ratings (5)


William GAO

Hristo Zhivomirov

Hi Stephen!
Thank you for your oppinion, I will take it into account.
I am well aware about colormaps pros and cons.
By the way, the reader could also refer to K. Moreland, “Diverging Color Maps for Scientific Visualization”, ISVC '09 Proceedings of the 5th International Symposium on Advances in Visual Computing: Part II, pp. 92-103, 2009; or A. Telea, Data Visualization: Principles and Practice, Boca Raton, CRC Press, 2015 about the topic.
In the next submission update, I may change the colormap to 'parula' one, indeed.
Let's see more users' comments...

Once again, thank you very much Stephen!
All best,

MATLAB Release Compatibility
Created with R2017b
Compatible with any release
Platform Compatibility
Windows macOS Linux

Inspired: Flip a Coin or Roll a Dice with Matlab

Community Treasure Hunt

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

Start Hunting!