# Proportion/Ratio response variable

I need some advice to understand the following code. We are working with lung data and usually we use LMS technique to calculate the reference curves. In order to calcualte the curves with LMS method from gamlss package we use the following code (forexample)

library(gamlss)
A<-lungFunction

m1 <- gamlss(slf ~ log(height) + pb(log(age)), sigma.fo =~pb(log(age)), nu.fo =~pb(log(age)), family = BCCGo(mu.link = "log"), data=A)

the link for µ needs to be the log.


It seems that LMS method is not appropriate method when the response variable is a ratio or proportion, So inflated logitSST distributions is proposed instead. In an article, the following code was used to calculate the centile curves for slf which is a proportion (0,1]. I could not understand why ga function and s function were used to define the µ. So any advice regarding that would be highly appreciated. I am also wondering how I can Implement the prediction equation and and the contribution of the splines (Mu,Sigma,nu) varies with age. In LMS method when the link function for Mu is log function then we take exp function for back transformation but I have no idea how we can do it when we define mu.formula = ~ ga(~s(log(height), log(age)))

library(gamlss.inf)

gen.Family("SST", "logit")

mf1 <- gamlssInf0to1(y=slf,
mu.formula = ~ ga(~s(log(height), log(age))),
sigma.formula = ~pb(log(age)),
nu.formula = ~pb(log(age)),
tau.formula = ~pb(log(age)),
xi1.formula = ~pb(log(age))+ pb(log(height)),
family = logitSST,
data = A,
n.cyc = 100,
trace = TRUE)

• What is the full name of "LMS"? Commented Jan 3, 2023 at 19:07
• ga is an interface to gam from the mgcv package. To generate the reference curves, you'd normally use the predict function. You don't need to backtransform anything by hand. Commented Jan 3, 2023 at 19:09
• @Zhanxiong apparently "the distribution at each covariate value is summarized by three parameters, the Box-Cox power $\lambda$, the mean $\mu$ and the coefficient of variation $\sigma$, and the initials of the parameters give the name to the LMS method" so Lambda-Mu-Sigma Commented Jan 3, 2023 at 20:30
• @ thanks for the reply. We need to present the equations. Forexample, when we use LMS method with long link function for Mu, the formula for mu would be: (forexample: mu = exp(-10.56310 + 2.27937·log(height) + 0.04112·log(age) + mu-spline). However, I have no idea how we can present the equation for mu when we use logitSST. Commented Jan 4, 2023 at 9:04
• @ Henry, thanks for the reply, You are right, The LMS method is equivalent to Box-Cox Cole and Green distribution (BCCG), and BCCG parameters (μ, σ, υ) are the approximate median, coefficient of variation and skewness. Commented Jan 4, 2023 at 9:09

Yes, ga is an interface to gam in the mgcv package. This is needed to include a bivariate smoother s(log(height), log(age)).

If y~logitSST(mu,sigma,nu,tau), then logit(y) = log(y/(1-y)) ~ SST(mu, sigma,nu,tau).

The default link functions for SST are:

identity for mu

log(sigma) for sigma

log(nu) for nu

log(tau-2) for tau

The reason for log(tau-2) is to ensure tau>2, so that the mean and variance of SST are finite. In fact mu=mean and sigma=standard deviation for SST.

• Did you really mean tau>2 ? Commented Jan 10, 2023 at 18:50