Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Predicted CEF values out of sample from npregress using the local constant option

    Hello,

    I am having trouble predicting specific CEF values using --npregress-- with the local constant option --estimator(constant)--. The exact command I first run is --npregress kernel y x, estimator(constant) noderivative--. The command will not run without the --noderivative-- option. My end goal is to get the prediction for CEF(x=0), where x=0 does not occur in my sample.


    I can do this when using the local linear option (the default of --npregress--) through the command --margins, at(x=0)--, but margins gives me the error "estimates post: matrix has missing values" when using local constant. I assume it has to do with the fact that local constant does not have a derivative term like local linear. But is there no other way to predict values for the CEF out of sample without margins, when I use the local constant option? That would seem to be a serious flaw with the command.

    Thanks for any help.

    Sam

  • #2
    Hi Samuel,
    I think the problem that you are facing is more about trying to do something that non-parametric analysis is not meant to do.
    Non-parametric regressions is good for obtaining interpolations (predictions of values that are within the range of the original value) but not extrapolation (predictions outside of the original range). You can still do that, under very strong assumptions and by hand, but they will be mostly wrong. In fact, My guess is that npregress is not allowing you because is trying to avoid doing something that is not meant to.
    If you think about it, the local constant estimator is a weighted mean using all the information around the point of interest. If you try to obtain the main of a value outside the range, there is NO information around that point of interest, thus you cannot obtain any prediction.

    HTH
    Fernando

    Comment


    • #3
      FernandoRios is I believe correct. npregress is smart conditional averaging of the data within their own support. There are no implications beyond that. It can be necessary to re-discover a major reason for using a functional form, namely that a well-chosen functional form may have some use beyond the data....

      Comment

      Working...
      X