【 MATLAB 】Contour plot of matrix(矩阵的等高线图)

Contour plot of matrix

矩阵的等高线图

等高线图显示矩阵Z的等值线。使用clabel标记轮廓线。

contour(Z) 绘制矩阵Z的等高线图,其中Z被解释为相对于x-y平面的高度。 Z必须至少是包含至少两个不同值的2乘2的矩阵。 x值对应于Z的列索引,y值对应于Z的行索引。自动选择轮廓级别。

contour(Z,n) 绘制具有n个轮廓水平的矩阵Z的等高线图,其中n是标量。 自动选择轮廓水平。

contour(Z,v) 绘制矩阵Z的等高线图,轮廓线位于单调增加矢量v中指定的数据值。要在特定值处显示单个轮廓线,请将v定义为具有两个元素的双元素矢量 等于所需的轮廓水平。 例如,要在级别k绘制轮廓线,请使用轮廓(Z,[k k])。 指定向量v会将LevelListMode属性设置为手动。

contour(X,Y,Z)contour(X,Y,Z,n), and contour(X,Y,Z,v) draw contour plots of Z using X and Y to determine the x and y values.

  • If X and Y are vectors, then length(X) must equal size(Z,2) and length(Y) must equal size(Z,1). The vectors must be strictly increasing or strictly decreasing and cannot contain any repeated values.

  • If X and Y are matrices, then their sizes must equal the size of Z. Typically, you should set X and Y so that the columns are strictly increasing or strictly decreasing and the rows are uniform (or the rows are strictly increasing or strictly decreasing and the columns are uniform).

If X or Y is irregularly spaced, then contour calculates contours using a regularly spaced contour grid, and then transforms the data to X or Y.

如果 X 和 Y 是向量,则 length(X) 必须等于 size(Z,2),也即是Z的列数,length(Y) 必须等于 size(Z,1),也即是Z的行数。 向量必须严格增加或严格减少,并且不能包含任何重复值。

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

李锐博恩

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值