matlab errorbare,【matlab】errorbare&errorbar

原谅我英语不好,把matlab说明文件复制到这里来注释一下……

ERRORBAR

Error bar plot.

ERRORBAR(X,Y,L,U) plots the graph of vector X vs.

vector Y with

error bars specified by the vectors L and U.

L and U contain the

lower and upper error ranges for each point in Y.

【L、U是bar的上下限,可以不等。若画相等的情况见下文的ERRORBAR(X,Y,E) or ERRORBAR(Y,E)

】 Each error bar

is L(i) + U(i) long and is drawn a distance of

U(i) above and L(i)

below the points in (X,Y).  The

vectors X,Y,L and U must all be

the same length.  If X,Y,L and U

are matrices then each column

produces a separate line.

ERRORBAR(X,Y,E) or ERRORBAR(Y,E) plots Y with

error bars [Y-E Y+E].

ERRORBAR(...,'LineSpec') uses the color and

linestyle specified by

the string 'LineSpec'.  The

color is applied to the data line and

error bars while the linestyle and marker are

applied to the data

line only.  See PLOT for

possibilities.

ERRORBAR(AX,...) plots into AX instead of

GCA.

H = ERRORBAR(...) returns a vector of

errorbarseries handles in H.

For example,

x = 1:10;

y = sin(x);

e =

std(y)*ones(size(x));

errorbar(x,y,e)

draws symmetric error bars of unit standard

deviation.

==========================================================

ERRORBARE Enhanced Errorbar

Function.

ERRORBARE(STY,X,Y,Xbar,Ybar,symbol)

It can draw errorbar along X/Y/Dual(双的)

axis

in normal,semilog,loglog coordinate

system,

and adjust length of top line

automatically,

can also control dotstyle and color in the same

way with errorbar.

If the lower and upper error range of x/y is

different, they should be

input as [lower,upper] if x/y is a column

vector;

for a row vector, they should be

[lower;uper].

parameter STY include 12

types:

v,h,d,vlogx,hlogx,dlogx,vlogy,hlogy,

dlogy,vlogd,hlogd,dlogd

where

v stands for vertical errorbar,

h draws horizontal

errorbar,【注意,这里转为水平后bar的长度是以x轴的刻度为准fig2。errorbar的bar长度是参考y轴刻度的fig1.】

d means dual direction,

logx corresponding to semilogx,can use preffix

v/h/d

logy corresponding to semilogy,can use preffix

v/h/d

logd corresponding to loglog,can use preffix

v/h/d

a4c26d1e5885305701be709a3d33442f.pngfig1

a4c26d1e5885305701be709a3d33442f.pngfig2

a4c26d1e5885305701be709a3d33442f.png把fig1中的XY互换了

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

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

余额充值