I was trying to plot a kernel density estimate for a 2D dataset. This is possible for 1D data (with 'smooth kdensity'), but not for 2D data.
While trying to do it with external tools, I realized that the existing 'dgrid3d' functionality already has every ingredient, and in fact does exactly what I need with a small modification. (dgrid3d uses the following formula to calculate the new grid values: z = Sum_i w(d_i) * z_i / Sum_i w(d_i). If I set all z_i to a constant, and omit the division, I get a KDE.)
This patch implements a new option to 'set dgrid3d': 'kdensity2d'. If given, it modifies the algorithm so that the division mentioned above does not take place.
Documentation and new demo included.
Looks good to me. Perhaps another sentence or two in the docs that defines or explains "kernel density"? I had to look it up separately.
Re-uploaded with slightly more documentation.
Feel free to reword it if it seems too un-English.
Looks OK, except there is a missing word:
"this smooth [surface] is plotted instead of the original data"
It still remains to add the option to save.c and show.c
2D kernel density estimate with dgrid3d - v3
I've totally forgot about those, but it's fixed now.
Are you going to go ahead and add this to CVS?
Thanks for the reminder, I've checked it it now.
WZe7PA <a href="http://psnzghkjbqin.com/">psnzghkjbqin</a>, [url=http://hpspyawzyksh.com/]hpspyawzyksh[/url], [link=http://qreqknnbjqjo.com/]qreqknnbjqjo[/link], http://tjoearljdiuo.com/
I could really use this feature. Is it in the CVS version? (And therefore, do I need to check it out) or has it been integrated into any official version?
It's in the CVS, but not in any released version.