search for: highdf

Displaying 2 results from an estimated 2 matches for "highdf".

2018 Jan 31
3
Problems with "predict" function ii
...;-lm(mitte~monat) s.lm abline(s.lm,lty=2) news<-data.frame(monat=nrow(sdf)+1) news fcs<-predict(s.lm,news,interval=?predict?) fcs points(1+nrow(ptr),fcs[,1],col=?grey?,pch=19) points(1+nrow(ptr),fcs[,2]) points(1+nrow(ptr),fcs[,3]) ptr<-rbind(ptr,c(1+nrow(ptr),fcs[2],fcs[1],fcs[3])) ptr highdf<-data.frame(ptr[,c(1,4)]) highdf colnames(highdf)<-c(?month?,?sales?) highdf detach(sdf) attach(highdf) h.lm<-lm(highdf[,2]~highdf[,1]) h.lm abline(h.lm,col="gray",lty=2) news<-data.frame(month=nrow(ptr)+1) news hcs<-predict(h.lm,news,interval=?predict?) hcs [[alternative...
2018 Jan 31
1
Problems with "predict" function
...o use different column labels in case that was the problem but it doesn't seem to make any difference I am also getting these weird warning messages telling me that things are being "masked": The following object is masked _by_ .GlobalEnv: sales The following object is masked from highdf (pos = 4): sales Etc Is it something to do with attaching the various data frames? I am a bit at sea on this and would be thankful for any pointers Nick My code: m<-runif(1,0,1) m mres<-m*(seq(1,12)) mres ssd<-rexp(1,1) ssd devs<-rep(0,length(mres)) for(i in 1:length(mres)){devs[...