search for: num_ob

Displaying 3 results from an estimated 3 matches for "num_ob".

Did you mean: num_mb
2011 Sep 10
0
npreg: plotting out of sample, extremely large bandwidths
...better? Many thanks in advance for any help with these issues. The simulated example follows below. I am not sure if this is relevant but I am using R 2.13.1 via RStudio 0.94.102 on a Windows 7 64-bit PC. The version of the np package is 0.40-9. rm(list=ls()) library("np") set.seed(1) num_obs <- 400 # generate data x1 <- runif(num_obs,min=0,max=1) x2 <- runif(num_obs,min=0,max=1) e <- rnorm(num_obs,0,1) y <- x1^2 + x2^2 + x1*x2 + e mydata <- data.frame(x1=x1,x2=x2,y=y,e=e) summary(mydata) rm(x1,x2,y,e) # PROBLEM 1: plotting out of sample # example 1: do not restric...
2011 May 18
4
Loop stopping after 1 iteration
...cript I have written: grid_2_series<-function(gage_handle,data_type,filename) series_name<-paste(gage_handle,data_type,sep="_") data_grid<-read.table(file=paste(filename,".txt",sep="")) num_rows_data<-nrow(data_grid)-1 num_cols_data<-ncol(data_grid)-4 num_obs<-num_rows_data*num_cols_data time_series<-matrix(nrow=0,ncol=2) for(i in 1:length(num_obs)){ rownum<-ceiling(i/31)+1 colnum<-if(i%%31==0){ 35 }else{ (i%%31)+4 } year<-data_grid[rownum,2] month<-data_grid[rownum,3] day<-colnum-4 date_string<-paste(month,day...
2011 May 23
2
days between dates
Hello, I have some unbalanced panel data that is measured on weekdays only (i.e., excluding Saturday and Sunday). I would like to get the number of days between dates such that the number of days between a Friday and a Monday is 1 (and not 3). Here is some code to illustrate my problem: library('Hmisc'); DATE <-