[R] nls problem

2012-07-03 Thread joerg van den hoff
hi list, used versions: 2.12.1 and 2.14.0 under ubuntu and macosx. I recently stumbled over a problem with `nls', which occurs if the model is not specified explicitly but via an evaluation of a 'call' object. simple example: 8<--

[R] 'R CMD check' fails with "evaluation nested too deeply: infinite recursion"

2009-10-28 Thread Joerg van den Hoff
I get the error Error : evaluation nested too deeply: infinite recursion / options(expressions=)? during a 'R CMD check ...' on one of my packages. The reason seems to be that this package is mutually dependent on another one (i.e. the DESCRIPTION files of package A lists package B under "Depen

[R] probability density function for maximum values in repeated finite samples from a normal distribution??

2009-09-28 Thread Joerg van den Hoff
this is probably not really a R specific question, if so apologies for off-topic posting: I'm interested in the probability density function of the maximum values from repeated samples of size N from a normal distribution: smp <- rnorm(N, meanval, stdev) with some mean 'meanval' and standard dev

Re: [R] one-site competition data // curve fitting

2008-07-08 Thread Joerg van den Hoff
On Mon, Jul 07, 2008 at 11:15:57AM +0200, Thiemo Schreiber wrote: > Hello everyone, > > I have biological data from a competition experiment where a free ligand is > titrated against the binding of a protein. > > Now, I would like to fit a standard on-site binding curve to this data in > order

Re: [R] Legend problem when exporting a plot to PDF

2008-04-29 Thread Joerg van den Hoff
On Tue, Apr 29, 2008 at 01:49:01PM +0200, Philipp Pagel wrote: > > > When exporting to PDF a graph with a legend, in the final PDF, the > > text is going beyond the legend box. > > > dev2bitmap("test.pdf", type="pdfwrite", h=6, w=6) > > The legend looks OK on the screen. I noticed that the size

[R] weighted nonlinear fits: `nls' and `eval'

2008-04-28 Thread Joerg van den Hoff
dear list, my question concerns the use of `eval' in defining the model formula for `nls' (version 2.6.2.). consider the following simple example, where the same model and data are used to perform unweighted and weighted fits. I intentionally used very uneven weights to guarantee large difference

Re: [R] efficiently replacing values in a matrix

2008-04-17 Thread Joerg van den Hoff
On Wed, Apr 16, 2008 at 03:56:26PM -0600, Matthew Keller wrote: > Yes Chuck, you're right. > just a comment: > Thanks for the help. It was a data.frame not a matrix (I had called > as.matrix() in my script much earlier but that line of code didn't run > because I misnamed the object!). My bad. T

Re: [R] ps or pdf

2008-04-01 Thread Joerg van den Hoff
have not followed the thread completely, but: have you tried `bitmap' with `type = pdfwrite' (or psgrb) for comparison? at least with `pdf' there are some issues which can be avoided by using ghostscript via `bitmap'. joerg On Mon, Mar 31, 2008 at 04:17:50PM -0400, Francois Pepin wrote: > Prof B

Re: [R] Compare parameter estimates of a nlsList object

2008-03-28 Thread Joerg van den Hoff
On Wed, Mar 26, 2008 at 05:27:22PM +1300, Frank Scherr wrote: > Hello together, > > Is there a tool to test the statistical differences between parameter > estimates of a nlsList fit? > > I fitted degradation data using the nlsList method and want to find out > whether derived rate constants

Re: [R] fitting "power model" in nls()

2007-12-02 Thread Joerg van den Hoff
On Sun, Dec 02, 2007 at 11:08:01AM -0800, Milton Cezar Ribeiro wrote: > Dear all, > I am still fighting against my "power model". > I tryed several times to use nls() but I can??t run it. > I am sending my variables and also the model which I would like to fit. > As you can see, this "power model"

Re: [R] Fwd: Empty list to use in a for cycle

2007-11-26 Thread Joerg van den Hoff
On Mon, Nov 26, 2007 at 04:35:53PM +0100, Niccolò Bassani wrote: > Dear R-users, > I'm posting a problem I already asked help for some time ago, because I'm > facing that problem once again and even because now, reading that old > e-mail, and the answer recevied, I understand I've not made myself c

Re: [R] `eval' and environment question

2007-11-13 Thread Joerg van den Hoff
On Tue, Nov 13, 2007 at 09:04:25AM -0500, Duncan Murdoch wrote: > On 11/13/2007 8:39 AM, Joerg van den Hoff wrote: > >my understanding of `eval' behaviour is obviously > >incomplete. > > > >myquestion: usually `eval(expr)' and `eval(expr

[R] `eval' and environment question

2007-11-13 Thread Joerg van den Hoff
my understanding of `eval' behaviour is obviously incomplete. myquestion: usually `eval(expr)' and `eval(expr, envir=parent.frame())' should be identical. why does the last `eval' (yielding `r3') in this code _not_ evaluate in the local environment of function `f' b

Re: [R] strange `nls' behaviour

2007-11-13 Thread Joerg van den Hoff
On Mon, Nov 12, 2007 at 06:59:56PM -0500, Duncan Murdoch wrote: > On 12/11/2007 2:56 PM, Joerg van den Hoff wrote: > >On Mon, Nov 12, 2007 at 11:09:21AM -0500, Duncan Murdoch wrote: > >>On 11/12/2007 9:14 AM, Joerg van den Hoff wrote: > >>>On Mon, Nov 12, 2007 at 07

Re: [R] How can I fitting this function from values.

2007-11-12 Thread Joerg van den Hoff
On Mon, Nov 12, 2007 at 04:27:26PM -0300, Horacio Castellini wrote: > Hi all, I'd like fit this function: > > G(t)=A*1/(1+t/B)*1/sqrt(1+t/C) > > where A, B and C are fitting constants that one like search. I have > got a fcs<-(t,G(t)) value table in a data frame. > > Any one can help me? Tahnks

Re: [R] strange `nls' behaviour

2007-11-12 Thread Joerg van den Hoff
On Mon, Nov 12, 2007 at 11:09:21AM -0500, Duncan Murdoch wrote: > On 11/12/2007 9:14 AM, Joerg van den Hoff wrote: > >On Mon, Nov 12, 2007 at 07:36:34AM -0500, Duncan Murdoch wrote: > >>On 11/12/2007 6:51 AM, Joerg van den Hoff wrote: > >>>I initially thought, thi

Re: [R] strange `nls' behaviour

2007-11-12 Thread Joerg van den Hoff
On Mon, Nov 12, 2007 at 03:25:38PM +0100, Martin Maechler wrote: > >>>>> "DM" == Duncan Murdoch <[EMAIL PROTECTED]> > >>>>> on Mon, 12 Nov 2007 07:36:34 -0500 writes: > > DM> On 11/12/2007 6:51 AM, Joerg van den Hoff wrote: &g

Re: [R] strange `nls' behaviour

2007-11-12 Thread Joerg van den Hoff
On Mon, Nov 12, 2007 at 07:36:34AM -0500, Duncan Murdoch wrote: > On 11/12/2007 6:51 AM, Joerg van den Hoff wrote: > >I initially thought, this should better be posted to r-devel > >but alas! no response. > > I think the reason there was no response is that your example

[R] strange `nls' behaviour

2007-11-12 Thread Joerg van den Hoff
I initially thought, this should better be posted to r-devel but alas! no response. so I try it here. sory for the lengthy explanation but it seems unavoidable. to quickly see the problem simply copy the litte example below and execute f(n=5) which crashes. called with n != 5 (and of co

Re: [R] a question on impulse responses

2007-10-15 Thread Joerg van den Hoff
On Sat, Oct 13, 2007 at 03:08:58PM +0300, Martin Ivanov wrote: > > Dear R users, > > I am using the vars package to calculate the impulse response functions and > the forecast error variance decomposition of a VAR model. Unfortunately I do > not know whether these functions assume unit or one s