Heights for both studies (years combined) over time Average of Dryland heights(avgheight) over time (adjdap)
I am trying to run a nonlinear model for a growth curve that is following a sigmoidal pattern but am having some issues with one of my studies.
This particular data set is for plant height, and I am trying to model plant height over time for two growing seasons. I have this model that I have been tweaking for each new data set, but it has been running correctly for my other biomass yield data. It is also running correctly for my irrigated study height data. I only get this error for my dryland study model. Here is a glimpse of my data:
Rows: 1,459
Columns: 17
$ ActDOY <dttm> 2019-09-23, 2019-09-23, 2019-09-23, 2019-0~
$ DOY <dbl> 265, 265, 265, 265, 265, 265, 265, 265, 265~
$ CDOY <dbl> 242, 242, 242, 242, 242, 242, 242, 242, 242~
$ Date <chr> "09/21", "09/21", "09/21", "09/21", "09/21"~
$ Year <dbl> 2019, 2019, 2019, 2019, 2019, 2019, 2019, 2~
$ avgheight <dbl> 112.33333, 111.33333, 108.66667, 102.33333,~
$ Field <chr> "F6", "F6", "F6", "F6", "F6", "F6", "F6", "~
$ Plot <dbl> 101, 102, 112, 203, 210, 212, 301, 305, 307~
$ treatment <dbl> 103, 103, 103, 103, 103, 103, 103, 103, 103~
$ heights <dbl> 10.8, 15.2, 6.4, 10.8, 6.4, 15.2, 6.4, 15.2~
$ height <chr> "medium", "high", "low", "medium", "low", "~
$ Block <chr> "1", "1", "1", "2", "2", "2", "3", "3", "3"~
$ dap <dbl> 80, 80, 80, 80, 80, 80, 80, 80, 80, 74, 74,~
$ irrigation <chr> "Irrigated", "Irrigated", "Irrigated", "Irr~
$ PD <dttm> 2019-06-07, 2019-06-07, 2019-06-07, 2019-0~
$ ADAP <dbl> 108, 108, 108, 108, 108, 108, 108, 108, 108~
$ AdjDAP <dbl> 85, 85, 85, 85, 85, 85, 85, 85, 85, 75, 75,~
Here is my current model:
```{r}
metadrm(avgheight ~ AdjDAP,
data = sunnHempht.dat %>% filter(irrigation == "Dryland"),
fct = LL.3(),
ind = Year,
struct = "UN") -> dry.metadrm
dry.start <- coef(dry.metadrm)
medrm(avgheight ~ AdjDAP,
data = sunnHempht.dat %>% filter(irrigation == "Dryland"),
random = b + d + e ~ 1 | Year,
fct = LL.3(),
start = dry.start) -> dry.medrm
dry.parms <- fixef(summary(dry.medrm))
summary(dry.medrm)
```
Here are the errors and warnings that result:
Error in solve.default(pdMatrix(a, factor = TRUE)) :
system is computationally singular: reciprocal condition number = 2.66326e-74
In addition: Warning message:
In nlme.formula(avgheight ~ meLL.3(AdjDAP, b, d, e), fixed = b + :
Iteration 1, LME step: nlminb() did not converge (code = 1). Do increase 'msMaxIter'!
Any help would be greatly appreciated on what I can do to get this running! Thanks!