![]() ![]() Granularity_factor = 1 % increase that for higher resolution Now to create and apply your custom colormap: %% Build and apply colormap This produces the figure below on the left. Zmax = max(max(Z)) zmin = min(min(Z)) zspan = zmax-zmin ![]() % normalise Z so the data are bound within ![]() To see it in code, I first needed to create some sample data (you did not provide a minimal working example!!): %% Sample data Of course if you want increased resolution you can multiply these numbers of lines by a coefficient, as long as the ratio of number of lines is respected. The lines 26 to 60 (mapping the values from 2.6 to 6.0) should be a gradient colormap.The lines 1 to 25 (mapping the values from 0.1 to 2.5) should be white.The first line (mapped to value 0) is set to grey.You can just build your custom colormap by respecting the proportions of the different intervals you want to separate.įor your example, with data bound by domain, you could choose a simple 60 colors (=60 lines) colormap. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |