title: Starting values for 4 parameter NLS - Chapman Richards function
body: <p>*Note - I have read several of the posts on how to find starting values for NLS - however, I have not found one with an equation of this form (i.e. 4 parameters, exponent raised to a power)</p>
  
  <p>I am struggling tremendously to find suitable starting values for the Chapman Richards equation, which is commonly used in forestry to model tree growth.</p>
  
  <pre><code>y(t) = α * (1 - β * exp(-k * t)^{1/(1-m)})
  </code></pre>
  
  <p>I typically try to find initial values by plotting a line with set parameters, and then tweaking it to fit the data more closely (Image 1). After this I would use the parameters in the function:</p>
  
  <pre><code>initial.test &lt;- chapmanRichards(seq(0:15),42,0.95,0.28, 0.67)
  plot(age,topHeight,type="p",xlab="year since planting",ylab="Dom height (m)", xlim = c(0,20), ylim = c(0, 50))
  lines(seq(0:15),initial.test,col="red")
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/dkTyR.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/dkTyR.png" alt="enter image description here"></a></p>
  
  <pre><code>nls(topHeight ~ chapmanRichards(age,a,b,k,m),start=list(a=42,b=0.95,k=0.28,m=0.67))
  </code></pre>
  
  <p>In this case, the program is able to fit the curve with the starting values provided. The problem, however, is when the data is a bit noisy, and after 2 hours of fiddling with the initial test values, I still can't find good enough starting values (Image 2 shows a few attempts on another dataset.</p>
  
  <p><a href="https://i.stack.imgur.com/EVXYu.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/EVXYu.png" alt="enter image description here"></a></p>
  
  <p>Can anyone advise on what a good way would be to find suitable starting values? I have thought of creating a matrix that basically runs a sequence for each of the parameters and looping the nls with those starting values, but not sure how the code would look. Any other advice would be greatly appreciated!</p>
  
  <p>PS - would this be something more suited to Excel - solver?</p>