Mountain as a plot for square matrix data

I have data as a square matrix. I want to build it as a meshgrid in Matlab (mountains with color gradients). In addition, if there is a large cliff, I want to designate it. Something like the one shown below

enter image description here

I have data

  _92765 _222156 _384259 _384249 _384247 _384250 _92765 -1 3.4 4.85106 8.12927 8.462 9.12643 _222156 3.4 -1 1.50877 3.66383 3.58554 3.69655 _384259 4.85106 1.50877 -1 4.48433 4.51367 4.14421 _384249 8.12927 3.66383 4.48433 -1 0.288 0.252 _384247 8.462 3.58554 4.51367 0.288 -1 0.196 _384250 9.12643 3.69655 4.14421 0.252 0.196 -1 

How can i do this? Thanks

+7
source share
1 answer

Have you looked at the wireframe () function in the lattice library?

Here is an example from online help:

 library(lattice) wireframe(volcano, shade = TRUE, aspect = c(61/87, 0.4), light.source = c(10,0,10)) 

enter image description here

+1
source

All Articles