A major update of stagedtrees (v2.0.0) is available on CRAN.
The update will almost surely break any code written with v1.0.2. Functions naming and functions parameters have been updated to simplify user experience. Check the complete changelog for details.
2.0.0
This version introduces major changes, in functions capabilities
and in functions naming.
These changes are almost surely breaking any previous code
using older versions of the package.
In particular, all functions named *.sevt
but class methods are now
called differently.
Moreover, various improvements and functionalities are added
to better deal with unobserved situations and to improve
computations.
Additional model selection methods based on clustering are
now available.
COMPLETE CHANGELOG:
- DESCRIPTION updated.
- documentation updated.
- improve code comments.
- reduced exported functions.
- removed the
fit
parameter fromfull
,indep
. Nowfull
andindep
always fit the model whilesevt
is just the basic constructor of thesevt
class. - in
full
andindep
by default unobserved situations are joined usingjoin_unobserved
, and probabilities are fitted only after the unobserved situations are joined, improving speed. Moreover, the name of the unobserved stages are stored asname_unobserved
in the staged tree object. - update internal function
new_label
to improve speed. plot.sevt
allows now to set edges color withcol_edges
.- In
plot.sevt
andbarplot.sevt
it is possible to specify stages that should be ignored and not plotted via theignore
argument, by default thename_unobserved
stages are ignored. plot.sevt
adds variables names by default (var_names
argument).- fix in
compare_stages
: because of changes inplot.sevt
we need to specify that the root is always considered identical. - internal function
stndnaming
accepts nowuniq
,prefix
and
ignore
arguments, which control how stage names are generated and
if some stage names should be left untouched (default: thename_unobserved
stages). - in
stages_bj
(previouslybj.sevt
) distance is now passed with a character and no longer as a function. - two new model selection function:
stages_hclust
andstages_kmeans
, to learn stage structure using hierarchical or
k-means clustering. - all model selection functions accept
scope
andignore
parameters that allow to specify among which variables run the algorithm and which stages should be left untouched (default: thename_unobserved
stages). - replace
1:length(x)
with the suggestedseq_along
in all code. - distance names in
stages_bj
andstages_hclust
are compatibles. - fixed bug in some probability distance functions when 0 probabilities.
- Conversion generic function
as.sevt
, only implemented one method forbn.fit
class from bnlearn package - fix
inclusions_stages
and provide better output.