24小时热门版块排行榜    

CyRhmU.jpeg
查看: 507  |  回复: 2

18811406325

新虫 (正式写手)

[求助] MATLAB小白求助画图的一个简单问题已有1人参与

情况是这样的,小弟我要用MATLAB把一个周期360度内的波形图分成36段每段10度,然后求取每段的有效值,最后再将它画成柱状图,横坐标是段数纵坐标是有效值。
求取有效值的公式我是有的。
我是初学者,所以问题也不难。恳请大神们讲解一下思路还有用到的指令。
回复此楼
已阅   回复此楼   关注TA 给TA发消息 送TA红花 TA的回帖

wurongjun

专家顾问 (职业作家)

【答案】应助回帖

★ ★ ★ ★ ★ ★ ★ ★ ★ ★
感谢参与,应助指数 +1
18811406325: 金币+10, 有帮助 2016-01-09 19:45:56
>> help bar

BAR Bar graph.
     BAR(X,Y) draws the columns of the M-by-N matrix Y as M groups of N
     vertical bars.  The vector X must be monotonically increasing or
     decreasing.

     BAR(Y) uses the default value of X=1:M.  For vector inputs, BAR(X,Y)
     or BAR(Y) draws LENGTH(Y) bars.  The colors are set by the colormap.

     BAR(X,Y,WIDTH) or BAR(Y,WIDTH) specifies the width of the bars. Values
     of WIDTH > 1, produce overlapped bars.  The default value is WIDTH=0.8

     BAR(...,'grouped') produces the default vertical grouped bar chart.
     BAR(...,'stacked') produces a vertical stacked bar chart.
     BAR(...,LINESPEC) uses the line color specified (one of 'rgbymckw').

     H = BAR(...) returns a vector of patch handles.

     Use SHADING FACETED to put edges on the bars.  Use SHADING FLAT to
     turn them off.

     Examples: subplot(3,1,1), bar(rand(10,5),'stacked'), colormap(cool)
               subplot(3,1,2), bar(0:.25:1,rand(5),1)
               subplot(3,1,3), bar(rand(2,3),.75,'grouped')

     See also HIST, PLOT, BARH.

Overloaded methods
    help fints/bar.m
善恶到头终有报,人间正道是沧桑.
2楼2016-01-07 22:46:57
已阅   回复此楼   关注TA 给TA发消息 送TA红花 TA的回帖

18811406325

新虫 (正式写手)

有大神吗
3楼2016-01-08 10:50:52
已阅   回复此楼   关注TA 给TA发消息 送TA红花 TA的回帖
相关版块跳转 我要订阅楼主 18811406325 的主题更新
信息提示
请填处理意见