Kernel Density Series Transformation

For questions regarding the import, export and manipulation of data in EViews, including graphing and basic statistics.

Moderators: EViews Gareth, EViews Jason, EViews Steve, EViews Moderator

diggetybo
Posts: 152
Joined: Mon Jun 23, 2014 12:04 am

Kernel Density Series Transformation

Postby diggetybo » Wed May 03, 2017 10:00 pm

If I have an existing series named x, and I want to store the kernel distribution of x in a series object named x_kernel, is there supported commands for this? The most common Epanechnikov formula would go something like:

Code: Select all

series x_kernel = (3/4)*(1-x^2) ....?


How can I implement the indicator function to truncate everything outside the domain [-1,1] to 0?

Please write the complete equation so I can see how you did it, thank you.

*Edit* On second thought, I guess I would need two series objects. One for the x values, and one for the y values.

EViews Glenn
EViews Developer
Posts: 2671
Joined: Wed Oct 15, 2008 9:17 am

Re: Kernel Density Series Transformation

Postby EViews Glenn » Fri May 05, 2017 9:48 am

You can store the distribution, but not in series objects as the number of evaluation points for the kernel estimate does not in general correspond to the workfile frequency.

Use Proc/Make Distribution Plot Data... from the menus, or the .distdata proc to store the results in a matrix object.

paolo.zanghieri
Posts: 49
Joined: Wed Mar 05, 2014 10:52 am

Re: Kernel Density Series Transformation

Postby paolo.zanghieri » Thu Feb 28, 2019 2:30 am

I have a similar problem. I want to rescale a series in the [0,1] interval using the percentiles of the kernel distribution. I guess I can do that with a long series of if, then else commands, but I wonder whether there is a quicker and more sensible way to do it. Thanks


Return to “Data Manipulation”

Who is online

Users browsing this forum: No registered users and 27 guests