Skip to content

Commit

Permalink
document that a markovchain object can now be created from a transiti…
Browse files Browse the repository at this point in the history
…on matrix of class Matrix
  • Loading branch information
reikoch committed Oct 7, 2024
1 parent f398c69 commit 697f1dc
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
5 changes: 3 additions & 2 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Package: markovchain
Type: Package
Title: Easy Handling Discrete Time Markov Chains
Version: 0.10.0.9007
Version: 0.10.0.9100
Authors@R: c(
person("Giorgio Alfredo", "Spedicato", role = c("aut", "cre"),
email = "[email protected]",comment = c(ORCID = "0000-0002-0315-8888")),
Expand All @@ -14,7 +14,8 @@ Authors@R: c(
person("Toni", "Giorgino", role="ctb", comment = c(ORCID = "0000-0001-6449-0596")),
person("Richèl J.C.", "Bilderbeek", role = "ctb", comment = c(ORCID = "0000-0003-1107-7049")),
person("Daniel", "Ebbert", email = "[email protected]", role = "ctb", comment = c(ORCID = "0000-0003-3666-7205")),
person("Shreyash", "Maheshwari", email = "[email protected]", role = "ctb")
person("Shreyash", "Maheshwari", email = "[email protected]", role = "ctb"),
person("Reinhold", "Koch", role = "ctb")
)
Maintainer: Giorgio Alfredo Spedicato <[email protected]>
Description: Functions and S4 methods to create and manage discrete time Markov
Expand Down
2 changes: 1 addition & 1 deletion src/probabilistic.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ using namespace std;
using namespace arma;

template <typename T>
T sortByDimNames(const T mat);
T sortByDimNames(const T m);

typedef unsigned int uint;

Expand Down
2 changes: 1 addition & 1 deletion vignettes/an_introduction_to_markovchain_package.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -325,7 +325,7 @@ defaultMc <- new("markovchain")

The quicker way to create `markovchain` objects is made possible thanks to the implemented `initialize` S4 method that checks that:

* the `transitionMatrix` to be a transition matrix, i.e., all entries to be probabilities and either all rows or all columns to sum up to one.
* the `transitionMatrix`, either of class matrix or Matrix, to be a transition matrix, i.e., all entries to be probabilities and either all rows or all columns to sum up to one.
* the columns and rows names of `transitionMatrix` to be defined and to coincide with `states` vector slot.

The `markovchain` objects can be collected in a list within `markovchainList` S4 objects as following example shows.
Expand Down

0 comments on commit 697f1dc

Please sign in to comment.