Revision 5eb62e61
Added by Benoit Parmentier almost 12 years ago
climate/research/oregon/interpolation/sampling_script_functions.R | ||
---|---|---|
18 | 18 |
# 4) ghcn_data_day: ghcn subsets by date |
19 | 19 |
|
20 | 20 |
#AUTHOR: Benoit Parmentier |
21 |
#DATE: 03/05/2013
|
|
21 |
#DATE: 03/13/2013
|
|
22 | 22 |
#PROJECT: NCEAS INPLANT: Environment and Organisms --TASK#363, TASK#558-- |
23 | 23 |
#Comments and TODO |
24 | 24 |
# |
... | ... | |
64 | 64 |
for(i in 2:3){ # start of the for loop #1 |
65 | 65 |
sampling_dat[,i]<-as.numeric(as.character(sampling_dat[,i])) |
66 | 66 |
} |
67 |
browser() |
|
67 |
|
|
68 | 68 |
sampling_dat$date<- as.character(sampling_dat[,1]) |
69 | 69 |
#ghcn.subsets <-lapply(dates, function(d) subset(ghcn, date==d)) #this creates a list of 10 or 365 subsets dataset based on dates |
70 | 70 |
ghcn.subsets <-lapply(as.character(sampling_dat$date), function(d) subset(ghcn, date==d)) #this creates a list of 10 or 365 subsets dataset based on dates |
Also available in: Unified diff
Sampling function, debugging dates arguments passing must be character string when called from raster prediction function