0
$\begingroup$

I am working with GAMLSS technique and I use LMS (with three parameters of mean,variation and skewness) method. I found the follwoing formula to calculate the lower limit of normal as the link function for mu is log fucntion.

LLN= exp(log(mu)+log(1-1.645*nu*sigma)/nu) 

In GAMLSS package, there is a function qBCCGo(p, mu = 1, sigma = 0.1, nu = 1, lower.tail = TRUE, log.p = FALSE) to calculate the lower limit of normal for Box-Cox Cole and Green distribution (p should be 0.05)

LLN= 5th percentile of that particular distribution

But the results of these two functions are not the same. I would be so thankful if you provide me some advice.

Forexample:

mu=0.8
nu=1.1
sigma=0.4

or

nu=1.2088855
 sigma=0.7251396
 mu=0.5203920

(for the second example the function in R gives us the answer but the formula would give us NA)

qBCCGo(0.05, mu = mu, sigma = sigma, nu = nu, lower.tail = TRUE, log.p = FALSE)
exp(log(mu)+log(1-1.645*nu*sigma)/nu)
$\endgroup$

2 Answers 2

1
$\begingroup$

qBCCGo is exact, so use that.

[Note the formula for LLN is approximate and

log(1-1.645 * nu * sigma) will be NA, if 1 < 1.645 * nu * sigma.]

Yes,

for calculating the ULN we need to use

qBCCGo(0.05, mu = mu, sigma = sigma, nu = nu, lower.tail = FALSE, log.p = FALSE)

or

qBCCGo(0.95, mu = mu, sigma = sigma, nu = nu, lower.tail = TRUE, log.p = FALSE)

which are exact and so should be used.

[The approximate formula is exp(log(mu)+log(1+1.645nusigma)/nu).]

$\endgroup$
3
  • $\begingroup$ Your answer could be improved with additional supporting information. Please edit to add further details, such as citations or documentation, so that others can confirm that your answer is correct. You can find more information on how to write good answers in the help center. $\endgroup$
    – Community Bot
    Commented Jan 12, 2023 at 14:32
  • $\begingroup$ @Robert, thanks so much, Just for double checking : for calculating the ULN we need to use qBCCGo(0.05, mu = mu, sigma = sigma, nu = nu, lower.tail = FALSE, log.p = FALSE) which is which is equivalent to exp(log(mu)+log(1+1.645*nu*sigma)/nu).Is this right? $\endgroup$
    – stats
    Commented Jan 13, 2023 at 8:43
  • 1
    $\begingroup$ These accounts are duplicates, Robert. Please visit stats.stackexchange.com/help/merging-accounts to merge them. $\endgroup$
    – whuber
    Commented Jan 16, 2023 at 17:07
1
$\begingroup$

mu=0.8

nu=1.1

sigma=0.4

qBCCGo(0.05, mu = mu, sigma = sigma, nu = nu, lower.tail = TRUE, log.p = FALSE)

gives an exact result.

However exp(log(mu)+log(1-1.645nusigma)/nu)

is an approximation.

The approximation should be quite accurate if sigma*abs(nu) < 0.27

[See page 441 of Rigby et al. (2019)]

For example:

mu=0.8

nu=1.1

sigma=0.2

qBCCGo(0.05, mu = mu, sigma = sigma, nu = nu, lower.tail = TRUE, log.p = FALSE)

0.5317892

exp(log(mu)+log(1-1.645nusigma)/nu)

0.5317606

Unfortunately in your example

sigma*abs(nu) = 0.4 * 1.1 = 0.44

$\endgroup$
1
  • $\begingroup$ thank you so much for the reply. I need to calculate the LLN for each ID after applying the LMS method. For several Ids the value of sigma*abs(nu) is more than 0.27. So when I use qBCCGo function, I can calculate it but the answer would be NA as soon as I run the formula. So, which function should I use? The formula or qBCCGo? $\endgroup$
    – stats
    Commented Jan 10, 2023 at 17:59

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.