zoukankan      html  css  js  c++  java
  • axis的用法--转载好文

     axis的用法

    转载自:https://www.cnblogs.com/10439-y/p/11788979.html

    其他参考https://ww2.mathworks.cn/help/matlab/ref/axes.html?s_tid=srchtitle

                      https://ww2.mathworks.cn/help/matlab/ref/matlab.graphics.axis.axes-properties.html

                      https://www.cnblogs.com/stxs/p/8721348.html

                      https://www.cnblogs.com/stxs/p/8617140.html

    1. axis([xmin xmax ymin ymax]): [ ]中分别给出x轴和y轴的最大值、最小值。( sets scaling for the x- and y-axes  on the current plot.)

    2. ​axis([xmin xmax ymin ymax zmin zmax]):[ ]中分别给出x轴、y轴、z轴的最大值、最小值。(sets the scaling for the x-, y- and z-axes on the current 3-D plot)

    3. axis equal 或axis(‘equal’) :表示x轴和y轴的单位长度相同。(sets the aspect ratio so that equal tick mark  increments on the x-,y- and z-axis are equal in size)

    4. ​axis square 或 axis(‘square’): 显示的坐标系呈正方形。(makes the current axis box square in size.)

    5. axis off 或 axis(‘off’) :关闭所有坐标轴线、刻度标记和标签。(turns off all axis labeling, tick marks and background)

    6. axis auto:​基于x、y和z的最大值和最小值来自动设置坐标轴的范围。用户可以只限定某一个坐标轴,如:axis 'auto x'用来限定x轴的范围;axis 'auto yz'用来限定y轴和z轴的范围。(returns the axis scaling to its default, automatic mode where,for each dimension, 'nice' limits are chosen based on the extents of all line, surface, patch, and image children.)

    7. axis manual:将坐标轴的范围锁定为当前范围。如果打开了hold on命令,则后续的图形都使用同样的坐标范围。该函数设置XLimMode、YLimMode和ZLimMode属性为manual值。(freezes the scaling at the current limits, so that if HOLD is turned on, subsequent plots will use the same limits.)

    8. axis tight:设置坐标轴的范围为数据的范围。(sets the axis limits to the range of the data.)

    9. axis fill:设置坐标轴的范围以及PlotBoxAspectRatio属性。坐标轴将填充整个矩形局域。只有PlotBoxAspectRatioMode或DataAspectRatioMode属性值为 manual时,该方法才起作用。(sets the axis limits and PlotBoxAspectRatio so that the axis fills the position rectangle.)

    10. a xis ij:将坐标系的原点设置到左上角。i轴为垂直轴,正方向为从上到下。j轴为水平轴,正方向为从左到右。(puts MATLAB into its "matrix" axes mode.  The coordinate system origin is at the upper left corner.  The i axis is vertical and is numbered from top to bottom.  The j axis is horizontal and is numbered from left to right.)

    11. axis xy:在默认的笛卡尔坐标系中绘制图形,坐标系的原点在左下角。x轴为水平坐标轴,正方向为从左到右;y轴为垂直坐标轴,正方向为从下到上。(puts MATLAB into its default "Cartesian" axes mode.  The  coordinate system origin is at the lower left corner.  The x axis is horizontal and is numbered from left to right.  The y axis is vertical and is numbered from bottom to top.)

    12. axis on:关闭所有坐标轴线、刻度标记和标签。( turns axis labeling, tick marks and background back on)

    13. axis image:​功能与axis equal相同。只不过坐标轴的边框紧贴在数据的四轴。多用来显示图片。(is the same as AXIS EQUAL except that the plot  box fits tightly around the data.)

    14. axis normal:​自动调节坐标轴的纵横比,从而是图形随窗口的形状而改变.(restores the current axis box to full size and removes any restrictions on the scaling of the units.This undoes the effects of AXIS SQUARE and AXIS EQUAL)

    15. v=axis:返回一个行向量,向量中的元素包含x、y和z轴的刻度因子。v具有四个或六个元素,这取决于当前坐标轴是二维的还是三维的。返回值是当前坐标轴的XLim、YLim和ZLim属性的值。(returns a row vector containing the scaling for the current plot.  If the current view is 2-D, V has four components; if it is 3-D, V has six components.)

    16. axis Vis3D:锁定坐标轴的纵横比​.(freezes aspect ratio properties to enable rotation of 3-D objects and overrides stretch-to-fill.)

     axis equal 用法--参考:https://zhidao.baidu.com/question/233490313.html

    解释:matlab函数图象很多时候为了把x和y的信息都表达得充分明显,会使x轴单位的实际长度和y轴单位的实际长度不一样。
    有利作用:比如说,y=0.00001*sin(x),系统就会自动拉长y轴来放大变化,方便我们看得清图象的函数变化。axis equal就是取消这种变化。把单位长度都变的一样。这样做的好处就是对于圆来说更像圆,
    弊端:但是对于一些变化很微小的函数就不是很直观,例如y=0.00000001* sin(x)看起来就有点像一条直线了

    本文版权归作者和博客园所有,欢迎转载,但请在文章也页面明显位置给出原文链接。如对文章有任何意见或者建议,欢迎评论。个人才疏学浅,文章如有错误,欢迎指正,也欢迎大家分享交流自己更好的方法! 此外有时由于太懒不是自己写上去的,引用了一些大佬的文章,如有忘记备注原文内容链接,实非故意。
  • 相关阅读:
    计算机基础学习路线路线详情:4步骤·5门课
    python课程体系是怎么样的?
    老猿学5G扫盲贴:中国移动5G融合计费漫游计费架构和路由方案
    老猿学5G扫盲贴:中国移动网络侧CHF主要功能及计费处理的主要过程
    moviepy音视频剪辑:moviepy中的剪辑相关类及关系
    老猿学5G扫盲贴:与用户和终端相关的名词UE、SUPI、GPSI、PEI
    PyQt+moviepy音视频剪辑实战文章目录
    PyQt+moviepy音视频剪辑实战2:一个剪裁视频文件精华内容留存工具的实现
    PyQt+moviepy音视频剪辑实战2:实现一个剪裁视频文件精华内容留存工具
    PyQt+moviepy音视频剪辑实战1:多个音视频合成顺序播放或同屏播放的视频文件实现详解
  • 原文地址:https://www.cnblogs.com/csymemory/p/13772913.html
Copyright © 2011-2022 走看看