'width' parameter in kdensity function

조회 수: 2 (최근 30일)
Devinya Herath
Devinya Herath 2011년 10월 1일
Can somebody plase explain me how to use the 'width' paramater of the kdensity function

채택된 답변

the cyclist
the cyclist 2011년 10월 1일
I suggest you read the "Bandwidth selection" section of this Wikipedia page: http://en.wikipedia.org/wiki/Kernel_density_estimation.
The width parameter is that bandwidth, and can be adjusted accordingly.
You can see the required syntax in "doc ksdensity".
  댓글 수: 3
Devinya Herath
Devinya Herath 2011년 10월 5일
Is there a direct method to find the value(s) of x corresponding to the peak(s) of the kernel density plot?
the cyclist
the cyclist 2011년 10월 5일
Call
[f,xi] = ksdensity(x);
then
[max_f index_to_max] = max(f);
finds the maxima and
xi(index_to_max)
gives the xi coordinates of the maxima.

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Workspace Variables and MAT Files에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by