具体程序如下:
- m1 <- nlme(model = WL~ exp(a)*D^b
- ,data = d1
- ,fixed = a+b~1
- ,random = a+b~1|Pn
- ,start = c(-2,1.5)
- ,control = nlmeControl(maxIter = 200,msMaxIter = 200))
- m3 <- update(m1,weights=varPower(form = ~D,fixed = 1.2))
错误:
> warnings(m3)
警告信息:
1: In conLin$Xy * varWeights(object) :
longer object length is not a multiple of shorter object length Error in cat("1: In conLin$Xy * varWeights(object) :\n longer object length is not a multiple of shorter object length", : argument 2 (type 'list') cannot be handled by 'cat'
如果用默认的varPower()选项,form = ~fitted(.),程序可以正常运行,但是这个fitted(.)在介绍中只说明是拟合值,并未说明是怎么来的,现在要输出也无法输出这个值
希望大家帮忙解决,有偿也可。部分数据在附件