How can I plot circular colormap for 0-24 hour phase?
Afficher commentaires plus anciens
I am plotting 24 hour phase figure where I want a circular colormap i.e. 0th hour and 24th hour should have same same but with smooth transition of color.
I was using following lines to generate the plot:
jet_wrap = vertcat(jet,flipud(jet));
colormap(jet_wrap);
In the figure the main problem is I can differentiate between the area shade 6th hour and 18th hour viz.
Also, whenever i am running my code "jet_wrap" sizes doubles every single time and even if I clear it's value before running it. Why it's happening?

3 commentaires
dpb
le 29 Août 2021
jet_wrap = vertcat(jet,flipud(jet));
says to take one copy of the colormap and paste a second (reversed) copy of it on the bottom. This will, indeed, be twice the size of the original colormap.
To keep the final result the same size as the original would require decimating by a factor of two -- with some issues of being precisely symmetric.
UTKARSH VERMA
le 30 Août 2021
When called without any arguments, jet() will return a color table with either 64 or 256 entries (depending on version). If the size of jet_wrap grows beyond length 128 (or 512), then either you have a variable called "jet", or you have some other thing changing the size of jet_wrap that you're not showing.
jet_wrap = vertcat(jet,flipud(jet));
size(jet_wrap,1)
jet_wrap = vertcat(jet,flipud(jet));
size(jet_wrap,1)
jet_wrap = vertcat(jet,flipud(jet));
size(jet_wrap,1)
Réponse acceptée
Plus de réponses (0)
Catégories
En savoir plus sur Color and Styling dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!


