Effacer les filtres
Effacer les filtres

Show only XGrid on Heatmap plot?

2 vues (au cours des 30 derniers jours)
yari lazzaro
yari lazzaro le 17 Nov 2018
Modifié(e) : yari lazzaro le 17 Nov 2018
Hi, I'm using a heatmap plot to show zero values in a matrix. I am using h.GridVisible = 'off' to hide the grid but actually I would like to see the horizontal grid lines but not the vertical ones. Is there a way to achieve that?
Thanks

Réponses (2)

KSSV
KSSV le 17 Nov 2018
[X,Y,Z] = peaks(100) ;
pcolor(X,Y,Z)
shading interp
hold on
plot(X',Y','k')

yari lazzaro
yari lazzaro le 17 Nov 2018
Modifié(e) : yari lazzaro le 17 Nov 2018
Thanks for your feedback. I find it hard to adapt it to my situation, I simply have a 200x15 matrix made of zeros and ones and by doing pcolor(X) I sort of achieve the same thing as heatmap(X) but I'm losing the possibility to set the ticks for each column/row of the heatmap plot. I could set them but they will be set in the intersections of the points not in the middle of the rows/columns.
Should you have further suggestions please let me know, thanks again.

Catégories

En savoir plus sur Data Distribution Plots dans Help Center et File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by