Main Content

长石板

Draw contours in volume slice planes

  • Draw contours in volume slice planes

Description

例子

长石板(X,,,,y,,,,z,,,,v,,,,Xslice,,,,yslice,,,,zslice在切片中绘制轮廓以获取体积数据v,,,,wherev确定轮廓颜色。指定X,,,,y,,,,andzas the coordinate data. SpecifyXslice,,,,yslice,,,,andzslice作为使用以下形式之一的切片位置:

  • 要绘制与特定轴正交的一个或多个切片平面,请将切片参数指定为标量或向量。

  • To draw a single slice along a surface, specify all the slice arguments as matrices that define a surface.

长石板(v,,,,Xslice,,,,yslice,,,,zslice使用默认坐标数据v。这(X,,,,y,,,,z)location for each element inv分别基于列,行和页面索引。

例子

长石板(___,,,,num指定每个切片要绘制的轮廓线的数量。将此选项与先前语法中的任何输入参数一起使用。

长石板(___,,,,lvlsspecifies the values at which to draw contour lines within each slice.

长石板(___,,,,method指定插值方法,其中method“线性”,,,,'cubic', 或者'nearest'

长石板(斧头,,,,___将其绘制到指定的轴上,而不是电流轴(GCA)。

s= ContourSlice(___返回修补创建的对象。

Examples

collapse all

Create a single slice plane through volumetric data and draw contours of the data values.

Create the matricesX,,,,y,,,,z,,,,andvfrom theflow数据集。在切片平面中绘制V轮廓,其中z = 0。

[x,y,z,v] =流;Zslice = 0;ConiorSlice(X,Y,Z,V,[],[],Zslice)网格on

图包含一个轴对象。轴对象包含41个类型补丁的对象。

通过体积数据创建多个切片平面。在每个切片平面中绘制数据值的轮廓。让MATLAB选择轮廓级别。

Createvas an array of volume data defined by v = X e - X 2 - y 2 - z 2 。Draw contours in three slice planes that are orthogonal to theX-斧头is at the values-1.2,,,,0.8,,,,and2。不要创建任何与y-斧头is orz- 通过指定空数组来轴。将轴视图更改为3-D视图,然后添加网格线。

[x,y,z] = meshgrid(-2:.2:2);v = X.*exp(-x。^2-y。^2-z。^2);XSLICE = [-1.2,0.8,2];yslice = [];zslice = [];ContourSlice(X,Y,Z,V,XSLICE,YSLICE,ZSLICE)视图(3)网格on

图包含一个轴对象。轴对象包含20个类型补丁的对象。

通过体积数据创建多个切片平面。在每个切片平面中绘制数据值的轮廓。指定the levels where you want to draw the contours. Then, add a colorbar.

Draw contours in three slice planes that are orthogonal to theX-斧头is at the values-1.2,,,,0.8,,,,and2。Draw contours for the volume data between the values-0.2and0.4,,,,spaced every0.01。添加一个配色栏以查看数据值如何映射到轮廓颜色。另外,将轴视图更改为3-D视图,然后添加网格线。

[x,y,z] = meshgrid(-2:.2:2);v = X.*exp(-x。^2-y。^2-z。^2);XSLICE = [-1.2,0.8,2];lvls = -0.2:0.01:0.4;ContourSlice(X,Y,Z,V,XSLICE,[],[],LVLS)Colorbar View(3)网格on

图包含一个轴对象。轴对象包含63个类型补丁的对象。

通过体积数据创建表面切片,并沿着音量数据的表面绘制轮廓。指定要绘制的轮廓级别的数量。

Createvas an array of volume data defined by v = X e - X 2 - y 2 - z 2 。这n, show a slice of the volume data along the surface defined by z = X 2 - y 2 。沿表面绘制20个轮廓。将轴视图更改为3-D视图,然后添加网格线。

[X,Y,Z] = meshgrid(-5:0.2:5); V = X.*exp(-X.^2-Y.^2-Z.^2); [xsurf,ysurf] = meshgrid(-2:0.2:2); zsurf = xsurf.^2-ysurf.^2; contourslice(X,Y,Z,V,xsurf,ysurf,zsurf,20) view(3) gridon

图包含一个轴对象。轴对象包含20个类型补丁的对象。

Input Arguments

collapse all

X- 轴协调数据,,,,specified as a vector or a 3-D array the same size asv。如果指定一个3-D阵列,则必须是单调的,并且是正交间隔的,好像由meshgrid功能。

数据类型:单身的|double|int8|int16|int32|int64|UINT8|uint16|UINT32|Uint64

y- 轴协调数据,,,,specified as a vector or a 3-D array the same size asv。如果指定一个3-D阵列,则必须是单调的,并且是正交间隔的,好像由meshgrid功能。

数据类型:单身的|double|int8|int16|int32|int64|UINT8|uint16|UINT32|Uint64

z- 轴协调数据,,,,specified as a vector or a 3-D array the same size asv。如果指定一个3-D阵列,则必须是单调的,并且是正交间隔的,好像由meshgrid功能。

数据类型:单身的|double|int8|int16|int32|int64|UINT8|uint16|UINT32|Uint64

volume data, specified as a 3-D array.

数据类型:单身的|double|int8|int16|int32|int64|UINT8|uint16|UINT32|Uint64

X- 轴切片值,,,,specified in one of these forms:

  • Scalar — Draw one slice plane orthogonal to theX- 指定位置的轴。

  • vector — Draw multiple slice planes orthogonal to theX- 指定位置的轴。

  • []-Do not draw any slice planes.

  • 矩阵 - 沿表面而不是平面绘制切片。如果您使用此选项,然后ysliceandzslicealso must be matrices that are the same size.

Example:[2 4]在值2和4处绘制与X轴正交的平面。

数据类型:单身的|double|int8|int16|int32|int64|UINT8|uint16|UINT32|Uint64

y- 轴切片值,,,,specified in one of these forms:

  • Scalar — Draw one slice plane orthogonal to they- 指定位置的轴。

  • vector — Draw multiple slice planes orthogonal to they- 指定位置的轴。

  • []-Do not draw any slice planes.

  • 矩阵 - 沿表面而不是平面绘制切片。如果您使用此选项,然后Xsliceandzslicealso must be matrices that are the same size.

Example:[2 4]在值2和4处绘制与Y轴正交的平面。

数据类型:单身的|double|int8|int16|int32|int64|UINT8|uint16|UINT32|Uint64

z- 轴切片值,,,,specified in one of these forms:

  • Scalar — Draw one slice plane orthogonal to thez- 指定位置的轴。

  • vector — Draw multiple slice planes orthogonal to thez- 指定位置的轴。

  • []-Do not draw any slice planes.

  • 矩阵 - 沿表面而不是平面绘制切片。如果您使用此选项,然后Xsliceandyslicealso must be matrices that are the same size.

Example:[2 4]draws slice planes orthogonal to the z-axis at the values 2 and 4.

数据类型:单身的|double|int8|int16|int32|int64|UINT8|uint16|UINT32|Uint64

每片轮廓线的数量,指定为标量。

Example:4在每个切片中绘制四个轮廓线。

数据类型:单身的|double|int8|int16|int32|int64|UINT8|uint16|UINT32|Uint64

Contour line levels, specified as a vector. If you want to draw a single contour line per slice at a particular level, then specify the vector in the form[LVL LVL]

Example:[1 3 5]draws contour lines at the levels 1, 3, and 5 within each slice.

Example:[4 4]draws a single contour line at the level 4 within each slice.

数据类型:单身的|double|int8|int16|int32|int64|UINT8|uint16|UINT32|Uint64

插值法,指定为以下值之一:

  • “线性”-Linear interpolation of the values at neighboring grid points in each respective dimension. This value is the default value when the slice is a surface.

  • 'cubic'-Cubic interpolation of the values at neighboring grid points in each respective dimension.

  • 'nearest'- 最近的网格点值。当切片是平面时,此值是默认值。

目标轴,指定为Axes目的。If you do not specify the axes, then长石板绘制到电流轴上。

Algorithms

长石板函数在绘制之前不会清除现有图。

扩展功能

版本历史记录

Introduced before R2006a