search for: grads

Displaying 20 results from an estimated 420 matches for "grads".

Did you mean: grade
2010 Apr 16
1
data frame manipulation
Dear group, Here is my data.frame : df <- structure(list(DESCRIPTION = c("PRM HGH GD ALU", "PRM HGH GD ALU", "PRIMARY NICKEL", "PRIMARY NICKEL", "PRIMARY NICKEL", "PRIMARY NICKEL", "STANDARD LEAD ", "STANDARD LEAD ", "STANDARD LEAD ", "STANDARD LEAD ", "STANDARD LEAD ",
2011 Feb 10
1
Newb Prediction Question using stepAIC and predict(), is R wrong?
...roblem?) The dataframe that I use to build the model is the same as the data I'm using to predict with. Here is a portion of what is happening.. This is the value it is predicting = > [1] 9.482975 Summary of the model Call: lm(formula = reservesub$paid ~ reservesub[, 3 + i] + reservesub$grads[, i] + reservesub$Sun + reservesub$Fri + reservesub$Sat) Residuals: Min 1Q Median 3Q Max -15.447 -4.993 -1.090 3.910 27.454 Coefficients: Estimate Std. Error t value Pr(>|t|) (Intercept) 5.71370 1.46449 3.902 0.000149 ***...
2010 Apr 15
1
sum rows in a data.frame...solution
Found this solution. It is maybe not the most elegant way, but it does the job. > a=as.data.frame(substr(lme$DESCRIPTION,1,14)) > colnames(a)=c("DESCRIPTION") > lme=as.data.frame(c(a,lme[,2:3])) > lme DESCRIPTION CLOSING.PRICE POSITION 1 PRIMARY NICKEL 25,755.7100 0 2 PRIMARY NICKEL 25,760.8600 0 3 PRM HGH GD ALU 2,415.9000 0
2007 Sep 17
0
2 commits - libswfdec/swfdec_bits.c
libswfdec/swfdec_bits.c | 52 ++++++++++++++---------------------------------- 1 file changed, 16 insertions(+), 36 deletions(-) New commits: diff-tree 66b4014d57faa03a37e3d11788110bad17c860e6 (from ca10e69db70a8396253e0fa2114bd6e3787d61d2) Author: Benjamin Otte <otte at gnome.org> Date: Mon Sep 17 11:31:24 2007 +0200 more bad duplication diff --git a/libswfdec/swfdec_bits.c
2007 Apr 22
0
3 commits - libswfdec/swfdec_bits.c libswfdec/swfdec_font.c libswfdec/swfdec_movie.c
libswfdec/swfdec_bits.c | 24 ++++++++++++++++++------ libswfdec/swfdec_font.c | 43 +++++++++++++++++++++++++++---------------- libswfdec/swfdec_movie.c | 4 ++++ 3 files changed, 49 insertions(+), 22 deletions(-) New commits: diff-tree 26a33bf08b5d9feeb8047274b312cee2999824ff (from ea79f997727fcd34b23b206be84b95c7e2f6d152) Author: Benjamin Otte <otte@gnome.org> Date: Sun Apr 22
2007 Jan 12
1
incorrect result of deriv (PR#9449)
Full_Name: Joerg Polzehl Version: 2.3.1 OS: x86_64, linux-gnu Submission from: (NULL) (62.141.176.22) I observed an incorrect behavior of function deriv when evaluating arguments of dnorm deriv(~dnorm(z,0,s),"z") expression({ .value <- dnorm(z, 0, s) .grad <- array(0, c(length(.value), 1), list(NULL, c("z"))) .grad[, "z"] <- -(z * dnorm(z))
2009 Nov 20
2
Problem with Numerical derivatives (numDeriv) and mvtnorm
I'm trying to obtain numerical derivative of a probability computed with mvtnorm with respect to its parameters using grad() and jacobian() from NumDeriv. To simplify the matter, here is an example: PP1 <- function(p){ thetac <- p thetae <- 0.323340333 thetab <- -0.280970036 thetao <- 0.770768082 ssigma <- diag(4) ssigma[1,2] <- 0.229502120
2006 Feb 16
2
Problem with scoping a variable value
Hi there, I have a function which has a variable called show as an input: richardson.grad <- function(func, x, d=0.01, eps=1e-4, r=6, show=F){ # do some things if(show) { cat("\n","first order approximations", "\n") print(a.mtr, 12) } #do more things and return } The show variable is being used as a flag to show intermediate
2013 Mar 10
1
Error with grad() for numerical differential of a function
Hello everyone, I have programmed a function and, among other things, it has to compute the differential of a function. I have been using the function grad() and I have programmed some simulated studies. I have testes with 72,576 different combinations of the initial values and now I got an error in only 4 situations. The error comes from the function grad() and I don't understand why. This
2004 May 14
2
NLME model question
Dear R-helpers I have a problem related to the use of NLME I think is simply a matter of getting the nlme coding correct, but i cannot get my brain around it I am analysing some 24 growth curves of some cells , and i wanted to say that there are significant differences between the curves in two parameters that describe the pattern of growth. these parameters are from a logistic (r & k)
2012 Jan 03
1
higher derivatives using deriv
Dear everyone, the following is obviously used to compute the nth derivative, which seems to work (deriv(sqrt(1 - x^2),x,n)) However, before using this, I wanted to make sure it does what I think it does but can't figure it out when reading the ?deriv info or any other documentation on deriv for that matter: deriv(expr, namevec, function.arg = NULL, tag = ".expr", hessian = FALSE,
2009 May 10
4
Partial Derivatives in R
Quick question: Which function do you use to calculate partial derivatives from a model equation? I've looked at deriv(), but think it gives derivatives, not partial derivatives. Of course my equation isn't this simple, but as an example, I'm looking for something that let's you control whether it's a partial or not, such as: somefunction(y~a+bx, with respect to x,
2010 Apr 06
2
Extracting formulae from expression() / deriv()
I am attempting to extract the derivative/ gradient from this expression df1p <- deriv(f1, "P") > df1p expression({ .value <- s - c - a * P .grad <- array(0, c(length(.value), 1L), list(NULL, c("P"))) .grad[, "P"] <- -a attr(.value, "gradient") <- .grad .value }) So in this case I want to extract the "-a".
2013 Mar 10
0
Steepest Ascent Algorithm
I am trying to code a steepest ascent algorithm to optimize parameters used in a survivor function type problem. My unknown parameters (alpha, Beta0, and Beta1) for which I have been able to optimize using Newton's method. I keep getting an error because my alpha becomes negative and I can't calculate the likelihood. Here is my log likelihood I am optimizing (in LaTex): l=\sum _{ i=1 }^{
2006 Nov 18
1
deriv when one term is indexed
Hi, I'm fitting a standard nonlinear model to the luminances measured from the red, green and blue guns of a TV display, using nls. The call is: dd.nls <- nls(Lum ~ Blev + beta[Gun] * GL^gamm, data = dd, start = st) where st was initally estimated using optim() st $Blev [1] -0.06551802 $beta [1] 1.509686e-05 4.555250e-05 7.322720e-06 $gamm [1] 2.511870 This works fine but I
2009 Oct 29
4
deriv() to take vector of expressions as 1st arg?
The deriv() function takes an 'expression' as its first argument). I was wondering if the this function can take an array or a vector of expressions as its first argument. Aside, I saw how to give a vector argument to the second argument. like to have something like: deriv(c(~x^2+y^3, ~x^5+y^6), c("x","y")) the documentation for this function talks about being able to
2001 May 28
0
bugs in deriv(*, *, function.arg = ) (PR#953)
Also, this should have gone in R-bugs quite a while ago : ------- start of forwarded message ------- From: Martin Maechler <maechler@stat.math.ethz.ch> To: R-core@stat.math.ethz.ch Subject: PROTECT() bugs in deriv(*, *, function.arg = ) Date: Mon, 16 Apr 2001 21:02:10 +0200 In R versions 0.50 and 0.64.2 , the following worked > deriv(expression(sin(cos(x) * y)),
2007 May 26
1
bug from nlm function (PR#9711)
Full_Name: bernardo moises lagos alvarez Version: 2.4.0 OS: Windows XP professional Submission from: (NULL) (152.74.219.16) I need obtained the MLE of weibull parameters using the nlm with exact gradient an hessian. I am doing. bug report :Erro en log(b) : el argumento "b" est? ausente, sin default 1.Construction to objectiv functin with n=1 data
2012 Aug 31
3
fitting lognormal censored data
Hi , I am trying to get some estimator based on lognormal distribution when we have left,interval, and right censored data. Since, there is now avalible pakage in R can help me in this, I had to write my own code using Newton Raphson method which requires first and second derivative of log likelihood but my problem after runing the code is the estimators were too high. with this email ,I provide
2007 Jul 30
2
deriv, loop
Hi, 2 questions: Question 1: example of what I currently do: for(i in 1:6){sink("temp.txt",append=TRUE) dput(i+0) sink()} x=scan(file="temp.txt") print(prod(x)) file.remove("C:/R-2.5.0/temp.txt") But how to convert the output of the loop to a vector that I can manipulate (by prod or sum etc), without having to write and append to a file? Question 2: >