R/writeOUTfile.R

Defines functions writeOUTfile

writeOUTfile <- function(yplantsim){

	if(!inherits(yplantsim, "yplantsim"))
		stop("Need object output by YplantDay.")
	
	pfile <- yplantsim$plant$pfile
	proot <- gsub("\\.p$","",pfile, ignore.case=TRUE)
	filen <- paste0(proot,"-YplantQMC.OUT")
	
	write.table(yplantsim$outdata, filen, sep="\t", quote=FALSE, row.names=FALSE)
	message("Results written to file: ", filen)

return(invisible(filen))
}

Try the YplantQMC package in your browser

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

YplantQMC documentation built on May 29, 2017, 7:02 p.m.