[Depmix-commits] r525 - pkg/depmixS4/R
noreply at r-forge.r-project.org
noreply at r-forge.r-project.org
Sun Jun 17 23:58:22 CEST 2012
Author: ingmarvisser
Date: 2012-06-17 23:58:22 +0200 (Sun, 17 Jun 2012)
New Revision: 525
Modified:
pkg/depmixS4/R/transInit.R
Log:
Removed the is.null(data) from condition that tests for trivial formula (~1) as it causes that the dimension of the return value of the dens function is incompatible with other functions (which expect short return values when the model is stationary=homogeneous in time).
Modified: pkg/depmixS4/R/transInit.R
===================================================================
--- pkg/depmixS4/R/transInit.R 2012-06-15 14:51:13 UTC (rev 524)
+++ pkg/depmixS4/R/transInit.R 2012-06-17 21:58:22 UTC (rev 525)
@@ -10,7 +10,8 @@
signature(formula="formula"),
function(formula,nstates,data=NULL,family=multinomial(),pstart=NULL,fixed=NULL,prob=TRUE, ...) {
call <- match.call()
- if(formula==formula(~1)&is.null(data)) {
+ if(formula==formula(~1)) { # &is.null(data) removed this in the condition as it
+ # creates the wrong dimension for the dens function when data is used (but not needed)
x <- matrix(1,ncol=1)
} else {
mf <- match.call(expand.dots = FALSE)
More information about the depmix-commits
mailing list