2014-04-10から1日間の記事一覧

Rのbs()関数の解読

Rのbs関数の解読 以下コピペ function (x, df = NULL, knots = NULL, degree = 3, intercept = FALSE, Boundary.knots = range(x)) { x <- x if (smart.mode.is("read")) { return(eval(smart.expression)) } nx <- names(x) x <- as.vector(x) nax <- is.na…