- Create your own ICDF estimation using kernel density estimation, allowing you to control iteration limits and convergence criteria.
- Preprocess your data (e.g., transformations) to mitigate convergence issues before using "ksdensity".
how to change the number of Newton method iterations
2 views (last 30 days)
Show older comments
I am using the ksdensity as follows
ksdensity(a,b,'function','icdf');
but I get a warning on the non-convergence.
I know that the kernel density first fit an initial inverse CDF and then refines the estimation using the Newton method. However, the newton iteration take 100 steps only and then stops. In order to see if I can converge I would like to increase this value.
Can anybody help to understand how to change such parameter (number of iterations)?
0 Comments
Answers (1)
Pratyush
on 14 May 2024
Hi Luigi,
The "ksdensity" function in MATLAB doesn't offer a direct way to adjust the maximum number of iterations for the Newton method used in estimating the inverse cumulative distribution function (ICDF). To address non-convergence issues, you have a few options:
A custom implementation involves estimating the density, integrating it to get the CDF, and then numerically finding the ICDF, which offers full control but requires careful numerical work.
0 Comments
See Also
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!