| To: | s-news@wubios.wustl.edu |
|---|---|
| Subject: | deriv Function and pulling out the answer. |
| From: | Ken Kelley <KKelley@ND.EDU> |
| Date: | Mon, 19 Nov 2001 18:35:41 -0500 |
| User-agent: | Mozilla/5.0 (Windows; U; Win98; en-US; rv:0.9.4) Gecko/20011019 Netscape6/6.2 |
Hello everyone,I was wondering if there is a way to pull the expression out of the deriv function. I get an answer but there does not seem to be an obvious way of pulling the answer out to use in other ways. Any help would be appreciated. I'm using S Plus 2000 on Windows NT.
> deriv.formula((Y ~ G^5 + 2*G), "G")
expression({
.value <- (G^5) + (2 * G)
.grad <- array(0, c(length(.value), 1), list(
NULL, "G"))
.grad[, "G"] <- (5 * (G^4)) + 2
attr(.value, "gradient") <- .grad
.value
}
)
Is there a way to pull out the (5*(G^4)) + 2?
Thanks,
Ken
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| ||
| Previous by Date: | Re: repeated measure ANOVA with NAs, Prof Brian Ripley |
|---|---|
| Next by Date: | Cattell's salient similarity index, Jacob L van Wyk |
| Previous by Thread: | repeated measure ANOVA with NAs, Olivier . Renaud |
| Next by Thread: | Cattell's salient similarity index, Jacob L van Wyk |
| Indexes: | [Date] [Thread] [Top] [All Lists] |