Re: [問題] 用matlab畫分布圖已回收
※ 引述《erdosl (stupid)》之銘言:
: 有一組data,經過某個轉換後,其fourier頻譜"看起來"很像高斯分布,想用matlab畫出
: 頻譜的高斯分布圖,請問該如何做?
: ps:
: histfit(data,length,'normal')會"吃掉"x軸的頻率訊息,而且我只要那個鐘型曲線
: ,不要直方圖 http://ppt.cc/8gEl
: 因為進一步想hold on,然後畫另一組data及其分布然後看交點,像這樣
: http://ppt.cc/Yl-4 想要看兩條不同顏色的線的高斯分布曲線的交點,辦得到嗎?
: 這還要請既會matlab也熟機率統計的高手"順便"教一下小弟histfit是什麼意思@@
: 謝謝!
我不懂統計 只是剛好最近在看 GUI
關於第一個問題 help 如下解釋
histfit(data,nbins) plots a histogram
of the values in the vector data using nbins bars
in the histogram. histfit(data) with nbins is
omitted, its value is set to the square root of the number of elements in
data. h = histfit(data,nbins) returns a
vector of handles to the plotted lines, where h(1) is the
handle to the histogram, h(2) is the handle to the density
curve.
所以只要照著做
>>
H=histfit(data);
set(H(1),'visible','off');
就可以只留下你所謂的鍾型曲線, 據我對 help 解釋的理解
這個你所謂的鐘型曲線 是所謂的常態分佈曲線
你所給的 data 繪製出直方圖 , 看起來 histfit 是在比較兩者差異
由你給的圖 可知直方圖與常態分佈曲線並不符合
所以解釋你的 data 為非常態分佈
以上是我對 help 的理解 如有錯誤 歡迎指正 ^^
第二題我看不懂 是要把峰值連成一條線嗎?
--
※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 220.133.57.44
推
03/20 14:30, , 1F
03/20 14:30, 1F
→
03/20 14:31, , 2F
03/20 14:31, 2F
討論串 (同標題文章)
本文引述了以下文章的的內容:
完整討論串 (本文為第 2 之 2 篇):