3
$\begingroup$

Consider you have some nonlinear function

\begin{align} y_i&=\epsilon_i f(\beta,x_i) \end{align}

where $\epsilon_i$ is log-normally distributed with mean 1, and \begin{equation} f(x,\beta)=\frac{\beta_1x}{1+\beta_2x} \end{equation}

One way to estimate $\beta_1$ and $\beta_2$ is to do nonlinear regression on the log transformed data using the following model

\begin{align} \log(y_i)&=\log(f(\beta,x_i)) + e_i \end{align}

where $e_i$ is now normally distributed (with a mean slightly below zero). However, given this saturating $f$ the log transformation squashes data close to the asymptote $\beta_1 / \beta_2$, which based on me playing around with simulated data can lead to poor fits, where the data closer to the origin seems to be counting too much towards the fit.

Based on this question there seems to be a trade-off between positively skewed data and the ill-effects of the transformation. My question is just how positively skewed does the error have to be for the benefits of taking log transform to outweigh the drawbacks if the error is log-normal? What other methods exist when the transformation is leading to fits you can tell are poor just by eyeballing the data? Is it best just to do a minimizing SSE calculation on the initial model simply ignoring that your data is positively skewed?

$\endgroup$
6
  • $\begingroup$ it was my bad, the title especially didn't help. I've played around with both minimizing RSS and also doing the same with the transformed data. Interestingly they both don't do that great with 29 data points and an 'unknown' log-normal std of 0.3. I suspect what is going on is that in addition to the transformation distorting the data, E[e]$<$0 may also cause problems. My first thought was to try and estimate the std, but then we have 3 parameters to estimate which may be tricky with so little data. The transformed regression is doing slightly better than nls on the non-transformed data. $\endgroup$ Jan 26, 2015 at 1:44
  • $\begingroup$ If the assumptions are correct, using nonlinear least squares for the transformed fit is maximum likelihood, which generally should perform quite well. However there might be convergence issues. Can you show win more detail what the problem is that you say is occuring? How are start values obtained? Are the results stable using different start values? $\endgroup$
    – Glen_b
    Jan 26, 2015 at 4:02
  • $\begingroup$ Is it maximum likelihood if $E[e] \neq 0$? The mean of the log-normal variable is one, which is not the same as $\mu=1$. I should try and write down the likelihood, that shouldn't be too hard here. I have discovered that the problem was that I was choosing x values too close together. I imagine that is a problem for doing regression problems in general, but I am curious with regards to your maximum likelihood statement. $\endgroup$ Jan 26, 2015 at 4:15
  • $\begingroup$ Sorry to have missed the point. The level will of course be biased by half the variance of the log of the error term ($\frac{1}{2}\sigma^2$); I think you can adjust for that. Is that all the problem is? $\endgroup$
    – Glen_b
    Jan 26, 2015 at 4:28
  • 1
    $\begingroup$ ideally, the idea is to maximize the likelihood of all the parameters simultaneously. Your iterative scheme should work for that, but you can always verify it (e.g. either by evaluating the (steepest direction of) the derivative at the end, or by taking small steps around the stopping point to check). There's also generic optimization functionality $\endgroup$
    – Glen_b
    Jan 26, 2015 at 5:08

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.