R/fitted.ellipsesummarylist.R

Defines functions fitted.ellipsesummarylist

Documented in fitted.ellipsesummarylist

fitted.ellipsesummarylist <- function(object,...){
  g <- object
  thenames <- g$Boot.Estimates[,1:(which(colnames(g$Boot.Estimates)=="b.x")-1)]
  thelengths <- lapply(g$models, function(x) length(x$pred.x))
  rowvec <- mapply(function(x,y) rep(x,each=y),1:length(thelengths),y=thelengths)
  thenames <- thenames[rowvec,]
  
  thefittedx<-lapply(g$models,function (x) x$pred.x)
  thefittedx <- unlist(thefittedx)
  thefittedy<-lapply(g$models,function (x) x$pred.y)
  thefittedy <- unlist(thefittedy)
  data.frame(thenames,"input"=thefittedx,"output"=thefittedy)
}

Try the hysteresis package in your browser

Any scripts or data that you put into this service are public.

hysteresis documentation built on May 15, 2021, 1:09 a.m.