similar to: typsize and fscale arguments to nlm

Displaying 20 results from an estimated 2000 matches similar to: "typsize and fscale arguments to nlm"

2000 Mar 06
1
nlm and optional arguments
It would be really nice if nlm took a set of "..." optional arguments that were passed through to the objective function. This level of hacking is probably slightly beyond me: is there a reason it would be technically difficult/inefficient? (I have a vague memory that it used to work this way either in S-PLUS or in some previous version of R, but I could easily be wrong.) Here's
2008 Jan 15
1
Viewing source code for .Internal functions
I am trying to view the source code of the function nlm in the stats package of R 2.4.1. I downloaded the source from CRAN and opened nlm.R, and it calls a .Internal function: .Internal(nlm(function(x) f(x, ...), p, hessian, typsize, fscale, msg, ndigit, gradtol, stepmax, steptol, iterlim)) This is the same thing I saw when entering the function name at the R command
2007 Jun 20
1
How to use "mix" to estimate the parameters for mixture gamma distribution?
Dear R users, Please help me on using "mix" function under package "mixdist". My data distribution shows there are two components for the mixture distribution: left part is an exponential and right part is a normal. So I plan to use "gamma" mixture distribution to estimate the parameters. Here is what I am using for the "mix" function. Test<-mix(x,
2002 Nov 14
0
nlm / fscale
Dear all, I am using the nlm(base) function for a simple least squares problem. The size (order of magnitude) of the minimized function near the final parameter set is normally about 1e-10. Using the fscale=1e-10 argument in nlm is inefficient (no minimization is performed, iterations=0 or 1). Nlm only works when the minimized function is multiplied by 1e10 (without changing the default
2010 Oct 13
1
Wierd nlm behaviour in 2.10.1 and 2.12.0 [Sec=Unclassified]
Hi all, When upgrading to 2.11.1 recently I noticed different results being produced by my code. After much digging I have finally narrowed it to a call to nlm(). This can be replicated by: FixedRemovals<-1836180125888 AbStageInitial<-2223033830403 Rates<- 0.3102445 nlm(function(rootM,Abund,Loss,OtherM) {(Loss-(rootM/(rootM+OtherM)* (1-exp(-(rootM+OtherM)))*
2001 Nov 25
2
another optimization question
Dear R list members, Since today seems to be the day for optimization questions, I have one that has been puzzling me: I've been doing some work on sem, my structural-equation modelling package. The models that the sem function in this package fits are essentially parametrizations of the multinormal distribution. The function uses optim and nlm sequentially to maximize a multinormal
2000 Dec 07
0
Tuning the nlm function
Hi Everyone, Is there a simple way to force nlm to take larger initial steps? Setting print.level = 2 allows me to inspect the step size at each iteration, but I appear not to have made any appreciable impact on it by changing values of typsize, fscale, steptol or stepmax. The steps repeatedly come out tiny, 1e-9 typically, and the algorithm is terminating not because the gradient is zero (it
2005 Oct 11
2
Sometimes having problems finding a minimum using optim(), optimize(), and nlm() (while searching for noncentral F parameters)
Hi everyone. I have a problem that I have been unable to determine either the best way to proceed and why the methods I'm trying to use sometimes fail. I'm using the pf() function in an optimization function to find a noncentrality parameter that leads to a specific value at a specified quantile. My goal is to have a general function that returns the noncentrality parameter that
2009 Aug 07
1
Bug in nlm, found using sem; failure in several flavors (PR#13881)
This message is in MIME format. The first part should be readable text, while the remaining parts are likely unreadable without MIME-aware tools. --1660387551-1458482416-1249639718=:2997 Content-Type: TEXT/PLAIN; CHARSET=US-ASCII; FORMAT=flowed Content-ID: <Pine.LNX.4.64.0908071039211.2997 at parser.ilovebacon.org> Hello, There appears to be a bug in the nlm function, which I
2018 Apr 17
1
Minor glitch in optim()
Having worked with optim() and related programs for years, it surprised me that I haven't noticed this before, but optim() is inconsistent in how it deals with bounds constraints specified at infinity. Here's an example: # optim-glitch-Ex.R x0<-c(1,2,3,4) fnt <- function(x, fscale=10){ yy <- length(x):1 val <- sum((yy*x)^2)*fscale } grt <- function(x, fscale=10){ nn
2009 Aug 07
1
Bug in nlm, found using sem; failure in several flavors (PR#13883)
This message is in MIME format. The first part should be readable text, while the remaining parts are likely unreadable without MIME-aware tools. --1660387551-150661043-1249684349=:2997 Content-Type: TEXT/PLAIN; charset=iso-8859-1; format=flowed Content-Transfer-Encoding: QUOTED-PRINTABLE Hi Jeff, =09As mentioned in my message, I *did* replicate on another platform.=20 One platform was
2017 Aug 11
2
Issues of R_pretty in src/appl/pretty.c
See https://stat.ethz.ch/pipermail/r-devel/2017-August/074746.html for the origin of the example here. That pretty(c(-1,1)*1e300, n = 1e9, min.n = 1) gave 20 intervals, far from 1e9, but pretty(c(-1,1)*1e300, n = 1e6, min.n = 1) gave 1000000 intervals (on a machine), made me trace through the code to function 'R_pretty' in https://svn.r-project.org/R/trunk/src/appl/pretty.c . *lo is
2006 Dec 16
1
max.col oddity
I've noticed that the max.col function with the default "random" option often gives unexpected results. For instance, in this test, it seems clear what the answer should be: > # second col should always be max > x1 = cbind(1:10, 2:11, -Inf) > > # this works fine > max.col(x1, "first") [1] 2 2 2 2 2 2 2 2 2 2 > > # this gives random answers >
2011 Sep 22
1
nlm's Hessian update method
Hi R-help! I'm trying to understand how R's nlm function updates its estimate of the Hessian matrix. The Dennis/Schnabel book cited in the references presents a number of different ways to do this, and seems to conclude that the positive-definite secant method (BFGS) works best in practice (p201). However, when I run my code through the optim function with the method as "BFGS",
2017 Aug 18
1
Issues of R_pretty in src/appl/pretty.c
Examples similar to pretty(c(-1,1)*1e300, n = 1e9, min.n = 1) with smaller 'n': pretty(c(-1,1)*1e304, n = 1e5, min.n = 1) pretty(c(-1,1)*1e306, n = 1e3, min.n = 1) A report on 'pretty' when working with integers, similar to what led to change of 'seq' fuzz, is https://bugs.r-project.org/bugzilla3/show_bug.cgi?id=15137 -------------------------------------------- On Tue,
2000 Feb 07
1
demo(nlm) error under R 0.99.0
I can't seem to get the demo(nlm) to run under R version 0.99.0 Anyone know a solution? > fgh <- function(x) { gr <- function(x1, x2) { c(-400 * x1 * (x2 - x1 * x1) - 2 * (1 - x1), 200 * (x2 - x1 * x1)) } h <- function(x1, x2) { a11 <- 2 - 400 * (x2 - x1 * x1) + 800 * x1 * x1 a21 <- -400 * .... [TRUNCATED] > nlm(fgh,
1999 Dec 16
1
nlm in R version 0.90
I am trying to obtain some more detail regarding the nlm function available in the latest release of R. Specifically, what mimimization routine is being used... and ... does there exist a fortran or C version of it? Thank you, Joanna Joanna Elizabeth MILLS, M.Sc. Ph: (902) 494-3747 Dalhousie University Fax: (902) 494-5130 Department of Mathematics and
2007 Mar 16
0
Segmentation fault in estimating structural equation models with the SEM package.
Dear R-users, I am running a large number of simulations and estimating a structural equation model for each one using the SEM package. Each run of my program has around 8000 simulations. Most of the time the program completes all of them correctly but sometimes I get a segmentation fault in the sem routine and my program stops with the following error message: > *** caught
2004 Aug 21
0
Convergence code in nlm function
Dear R users, I am using the nlm function for minimization of the very non-linear function of four parameters. I am running 100 simulations and almost always I get the convergence code =2 (Successive iterates within tolerance. Current iterate is probably solution.) [about 75 times of 100]. Frequently, 3 of 4 relative gradients are close to zero and the fourth is huge but there are also cases
2009 Aug 07
0
Bug in nlm, found using sem; failure in several flavors (PR#13882)
Adam, It seems that your attachment didn't make it through. That aside, my experience with strange errors like those (random type not implemented ones) has been that you may be looking at a memory problem on you machine. Given that you can't replicate on another platform (and the .csv file didn't come through), I would think it wise to start there. My 2c. And I love bacon too :)