search for: indepnm

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

Did you mean: indent
2009 Feb 07
3
Output results to a single postscript document
...r) library(MASS) library(nlme) library(dyn) library(wle) library(lasso2) library(zoo) tdata <- ts(read.table("C:/tmp/data.csv" ,sep = ",",header=TRUE)) print(tdata) res <- function(dep, indep, fn, env = parent.frame()) { depnm <- deparse(substitute(dep)) indepnm <- deparse(substitute(indep)) fo <- sprintf("%s ~ lag(%s, -1) + %s", depnm, depnm, indepnm) fo <- as.formula(fo, env = env) mod <- do.call(dyn$lm, list(fo)) summ<- summary(mod) chart <- function(mod) { postscript(file="fig.p...
2009 Feb 03
1
How to show variables used in lm function call?
Hello R users, I am new to R and am wondering if anyone can help me out with the following issue: I wrote a function to build ts models using different inputs, but when R displays the call for a model, I cannot tell which variables it is using because it shows the arguments instead of the real variables passed to the function. (e.g Call: lm(formula = dyn(dep ~ lag(dep, -1) + indep)) --->