Commit ce54111
Guard against zero/non-finite sigma_diag in CWRES computation
When residual error variance is zero, negative, or non-finite for any
observation (e.g. both error$prop and error$add are 0 for an obs_type),
return cwres=NA and vcov=NULL with a warning identifying the offending
observations, instead of silently producing Inf/NaN.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>1 parent 287fb35 commit ce54111
1 file changed
Lines changed: 11 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
114 | 114 | | |
115 | 115 | | |
116 | 116 | | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
117 | 128 | | |
118 | 129 | | |
119 | 130 | | |
| |||
0 commit comments