histfit using Kernel function with a specific bandwith?
Mostrar comentarios más antiguos
Hi,
Can anyone tell me if there is way use histfit with a Kernel function, but also choose the bandwidth for the Kernel function. For example, I know I can use histfit like this:
histfit(data,10,'kernel')
...and get a nice fitted histogram with 10 bins. But, how can I change the bandwidth that is used in the Kernel function? I know how to do this using ksdensity:
[f,xi] = ksdensity(data,'width',mywidth)
...can this be applied to histfit?
Thanks in advance, Dan.
Respuestas (1)
Dan
el 10 de Oct. de 2013
2 comentarios
Mark van den Bosch
el 13 de Jun. de 2021
Great answer!
Francesca Lo Iacono
el 23 de Mzo. de 2022
Hi!
is the following line the only one you have modified?
"pd = fitdist(data,dist,'width',w);"
Categorías
Más información sobre Kernel Distribution en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!