Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我的程序的输出是一个区域图,并且有一个图形的标题但我也想在颜色条上放一个标题。我已经搜索了很多功能,但我无法做到这一点。谁能帮我 ??
使用颜色栏的句柄输出相对容易做到这一点:
imagesc(randn(10)); h = colorbar; title(h,'my colorbar')
除了皮特的出色回答,如果你想在侧面colorbar使用标签:
colorbar
[X,Y,Z] = peaks; figure; contourf(X,Y,Z,20); h = colorbar; ylabel(h,'Side colorbar label');