The coefficients of linexp fits to gastric emptying curves are generally used in mixed-models to analyze group and meal difference. The distribution of the extracted parameters is often highly skewed, so before using linear models or estimates of reference ranges with functions in package referenceInterval or Hmisc, a transformation might be required.

From a large corpus of gastric emptying curves analyzed with nonlinear fits of the linexp function, the following recommendations for transformation were obtained using the boxcox and the logtrans function in package MASS:

Linexp parameter tempt

Stable recommendation: log(tempt)

Overshoot parameter kappa

Try the logarithmic transformation log(kappa), but make sure that you have no non-positive values of kappa. Values of kappa near zero anyway are not very useful, so a prior when using Stan to fit might help. Even better, fit the logarithm of both kappa and tempt with nlme instead of the untransformed variables.

Half-emptying time t50

Stable recommendation: t50^(-0.5), or 1/sqrt(t50)

Initial volumeParameter v0

Surprising, and possibly not stable: v0^(-1), or 1/v0

I had expected that no transformation would be required, but in the existing records the tails were quit asymmetric due to early emptying.

Slope in t50 slope_t50

Try : log(slope_t50)

The log transformation is moderately stable, an offset might be required.


A transformation is required if you want to determine reference intervals, and you have data from fewer than 120 subjects or patients, so that the non-parametric method cannot be used. The robust method proposed in the official guideline C28-A3 gets around problems with outliers, but cannot graciously handle systematic skewness. For example, with untransformed t50 and tempt, negative lower limits for reference ranges are not uncommon.

If you use lme or lmer to compare between treatment averages, using transformations is not as important, since mixed models behave reasonably with moderate skewness.

The above are recommendations - your data may need different transformations. Use MASS::boxcox for interactive checks or one of the functions in package car. However, do not go overboard; if you find a power transformation of -0.6 or -0.7 for t50, check if the above rounded suggestion of -0.5 would also be reasonable. Using arbitrary transformation always runs into the risk of giving irreproducible result.

Next Post Previous Post