https://github.com/cran/flexmix
Raw File
Tip revision: 5cad1deeb850c1cb00d02de0e8220cdf1a161018 authored by Bettina Gruen on 24 January 2011, 00:00:00 UTC
version 2.3-3
Tip revision: 5cad1de
group.R
setMethod("group", signature(object="flexmix"), function(object) {
  group <- object@group
  if (!length(group)) group <- group(object@model[[1]])
  group
})

setMethod("group", signature(object="FLXM"), function(object) {
  factor(seq_len(nrow(object@x)))
})

setMethod("group", signature(object="FLXMRglmfix"), function(object) {
  factor(seq_len(nrow(object@x)/sum(object@nestedformula@k)))
})
back to top