[R] about dpik

2012-07-17 Thread chester123
Thanks in advance here. I use dpik() function to calculate the bandwidth h. Following is the related code: h<-dpik(x,scalest="minim",level=2L,kernel="normal",canonical=FALSE,gridsize=401L,range.x=range(x),truncate=TRUE) But there is warning messages: 1: In bkfe(gcounts, 6L, alpha, range.x = c(sa

Re: [R] about dpik

2012-07-16 Thread arun
1<-dat1$value is.vector(dat1) [1] TRUE  head(dat1) [1] "X12002" "X12027" "X12054" "X12084" "X12085" "X12115" A.K. - Original Message - From: chester123 To: r-help@r-project.org Cc: Sent: Monday, July 16, 2012 4:26 PM Subject:

[R] about dpik

2012-07-16 Thread chester123
Thank you for your reply. I know the x in dpik() means the vector. But I don't know how to import into c() with a huge metadata (>1000). Following is my some try, and the h is: [1] 0.001180569, which seems to be feasible. x<-c(-0.00109349389485645,-0.00145304131152137,0.00023685387037116,0.00579

Re: [R] About dpik function

2012-07-16 Thread chester123
The following is the related code and the metadata.I have tried my best to modify and test but the error always happened.I really don't know what it means. Please check it form me. Thanks in advance. Regards Date: Sun, 15 Jul 2012 23:26:57 -0700 From: ml-node+s789695n4636611...@n4.nabble.com To

Re: [R] About dpik function

2012-07-15 Thread Prof Brian Ripley
On 15/07/2012 19:57, chester123 wrote: Hi there and thanks in advance. Nowadays I am working on the plug-in bandwidth selection with R. Firstly, my So why use package KernSmooth and not the methods in R itself? 1010 data is the return rate from Yahoo Finance. Secondly, my code is following:

[R] About dpik function

2012-07-15 Thread chester123
Hi there and thanks in advance. Nowadays I am working on the plug-in bandwidth selection with R. Firstly, my 1010 data is the return rate from Yahoo Finance. Secondly, my code is following: > r=read.table("/Users/user/Desktop/research/a.txt",sep=",",header=TRUE) > x<-r[8:1010,] > library(KernSmoot