フィルターのクリア

Can I create a colorbar that is not associated to a figure?

8 ビュー (過去 30 日間)
Samantha Clayton
Samantha Clayton 2018 年 6 月 11 日
回答済み: Image Analyst 2018 年 6 月 11 日
Can I create a colorbar that is not associated to a figure? I have created a series of heat maps that I want a colorbar with, but it is not possible to change any properties of the colorbar from a heatmap. Thus, I want to know if it is possible to create one just from my limits that is not attached to the heatmap so I can adjust it.

採用された回答

Image Analyst
Image Analyst 2018 年 6 月 11 日
Samantha, try this:
rows = 512; % Whatever size you want.
columns = 50;
cmap = hsv(rows);
colorImage = ind2rgb([1:rows]', cmap);
colorImage = imresize(colorImage, [rows, columns], 'nearest');
imshow(colorImage);
axis on;

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeColormaps についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by