In R I wish to perform non linear mixed effect models by assigning the terms QY, ALOS and expenditure as fixed variables and Month as a random variable. Is this the right format to perform the analysis? (Note : QY stands for quality of life, ALOS refers to average length of stay, Expenditure refers to the total expenditure borne by the patient during his surgery, DC refers to direct cost and IC is the indirect cost)
The dataset looks like :
> head(sur_2019)
# A tibble: 6 x 6
Month ALOS Expenditure IC DC QY
<chr> <dbl> <dbl> <dbl> <dbl> <dbl>
1 January 3.2 17800 4560 13240 0.0984
2 February 4.86 26790 5000 21790 1.08
3 March 4.2 42500 7500 35000 0.843
4 April 3.5 25000 5850 19150 0.234
5 May 3.5 80000 16100 63900 0.385
6 June 3.07 22780 6780 16000 0.120
Analysis:
m1<-lme(QY~ALOS+Expenditure+Month,
data=sur_2019, fixed=QY~ALOS+Expenditure,
random=~1|Month, na.action = na.omit,
start=c(QY=1, ALOS=1, Expenditure=100))
- Error in lme(QY ~ ALOS + Expenditure + Month, data = sur_2019, fixed = QY ~ : unused argument (start = c(QY = 1, ALOS = 1, Expenditure = 100))
- Error in MEEM(object, conLin, control$niterEM) : Singularity in backsolve at level 0, block 1