Displaying 2 results from an estimated 2 matches for "fechasiembra".
2010 May 31
2
Problems with apply
...he apply I am doing:
PromP <- function(HistRio,AnaQuim){
xx <- c(0,0,0)
if(length(which(AnaQuim$SecSte==HistRio$SecSte))>0){ xx[1]<-1 }
if(length(which(as.Date(AnaQuim$A?O1)<=as.Date(HistRio$FinCorte)))>0){ xx[2]
<- 1}
if( length(which(as.Date(AnaQuim$A?O1)>=as.Date(HistRio$FechaSiembra)))>0){
xx[3]<-1 }
if( length(which(as.Date(AnaQuim$A?O1)>=as.Date(HistRio$FechaSiembra)))>0 &
length(which(as.Date(AnaQuim$A?O1)<=as.Date(HistRio$FinCorte)))>0 ){ xx[4]
<- 2}
return(xx)
}
zz<- apply(HistRio,1,PromP,AnaQuim)
and if I do exactly the same with a for
xx <...
2010 Sep 16
1
Problems creating a Panel
Hello, I am trying to create a panel with the attached data frame. using the
following code:
> PanelRio = DataRiopaila[which(duplicated(DataRiopaila$SEC_STE)==T),]
> PanelRio=plm.data(PanelRio,index=c("SEC_STE","FechaSiembra"))
series
Pluv3Meses,PluvMes4al10,Pluv2UltimosMeses,Rad3Meses,RadMes4al10,Rad2UltimosMeses
are NA and have been removed
It tells me it removes couple of series because they are NA, and I don't
understand why because if I do:
> PanelRio = DataRiopaila[which(duplicated(DataRiopaila$SEC...