# Generate simulated data
data = cleanup_data(simulate_breathtest_data())
# Fit with the population method
fit = nlme_fit(data)
# All coefficients in the long form
coef(fit)
# Access coefficients directly
fit$coef
# Only t50 by Maes/Ghoos
# Can also be used with stan fit (slow!)
if (FALSE) {
if (require("breathteststan")) {
fit = stan_fit(data, iter = 300, chain = 1)
coef(fit)
# We get quantiles here in key/value format
unique(fit$coef$stat)
}
}
Run the code above in your browser using DataLab