[R] Bandwidth selection for ksmooth( )

From: Amir Safari <amsa36060_at_yahoo.com>
Date: Thu 08 Dec 2005 - 21:29:22 EST


     Dear R Users,
  Before running ksmooth( ), a suitable bandwidth selection is needed. I use some functions for this task and receive these results for my data:   width.SJ(y,nb=100,method="ste") : 40.25   bcv(y,nb=100) : 40.53
  ucv(y) : 41.26
  bandwidth.nrd(y) : 45.43
  After implementing the function ksmooth(x,y, bandwidth= each of abovementioned bandwidths), I have some NAs in output with regard to each bandwidth. But if the bandwidth be equal to 62 or bigger, then the function ksmooth(x,y, bandwidth=62 or bigger) works without NA,i.e., the bandwidth must be at least 62 in order to not have NA in output.   That was the first case. In second case, I have to choose bandwidth bigger than the number of observations in order to not have NA in output of the function of ksmooth().   What is my mistake ?
  Thank you for any help.
  Amir Safari             


        [[alternative HTML version deleted]]

R-help@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html Received on Thu Dec 08 21:38:03 2005

This archive was generated by hypermail 2.1.8 : Fri 03 Mar 2006 - 03:41:34 EST