diff options
author | jranke <jranke@edb9625f-4e0d-4859-8d74-9fd3b1da38cb> | 2013-06-18 14:08:11 +0000 |
---|---|---|
committer | jranke <jranke@edb9625f-4e0d-4859-8d74-9fd3b1da38cb> | 2013-06-18 14:08:11 +0000 |
commit | ee699808c8e9eb63cab2b3102e3cc6eb97c5ce71 (patch) | |
tree | d5aa39dca90e74eb6d8c83e7d1977abf4a3ce999 /R/mkinfit.R | |
parent | 6168089ac43664c10ca2dc1281c8648fbf3b35a9 (diff) |
Pending check-in of stuff started at east one month ago:
- avoid returning factors in the data frame in mkin_wide_to_long
- stop returning useless results with eigenvalue based solutions when observed absolute values are all very small
- better test case for schaefer97 data making use of stepwise fitting - but the solution obtained in one step is
better...
git-svn-id: svn+ssh://svn.r-forge.r-project.org/svnroot/kinfit/pkg/mkin@83 edb9625f-4e0d-4859-8d74-9fd3b1da38cb
Diffstat (limited to 'R/mkinfit.R')
-rw-r--r-- | R/mkinfit.R | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/R/mkinfit.R b/R/mkinfit.R index cf018f0..cdf5429 100644 --- a/R/mkinfit.R +++ b/R/mkinfit.R @@ -108,6 +108,9 @@ mkinfit <- function(mkinmod, observed, } else {
if (is.matrix(mkinmod$coefmat)) {
solution_type = "eigen"
+ if (max(observed$value, na.rm = TRUE) < 0.1) {
+ stop("The combination of small observed values (all < 0.1) and solution_type = eigen is error-prone")
+ }
} else {
solution_type = "deSolve"
}
|