From 53b332d3c6e7a7440b6ad9752f5505f3bd2ff680 Mon Sep 17 00:00:00 2001 From: Daisuke Oyama Date: Fri, 22 Sep 2017 14:07:39 +0900 Subject: [PATCH 1/2] DOC: Fix a math definition in docstring --- quantecon/markov/core.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/quantecon/markov/core.py b/quantecon/markov/core.py index 65fe2645f..4d70125d5 100644 --- a/quantecon/markov/core.py +++ b/quantecon/markov/core.py @@ -36,10 +36,10 @@ directed graph :math:`\Gamma(P)`, where the condensation of :math:`\Gamma(P)` is a directed graph in which each SCC is replaced with a single node and there is an edge from one SCC :math:`C` to another SCC -:math:`C'` if :math:`C \neq C'` and some node in :math:`C` has access to -some node in :math:`C'`. A recurrent class is also called a *closed -communication class*. The condensation is acyclic, so that there exists -at least one recurrent class. +:math:`C'` if :math:`C \neq C'` and there is an edge from some node in +:math:`C` to some node in :math:`C'`. A recurrent class is also called a +*closed communication class*. The condensation is acyclic, so that there +exists at least one recurrent class. For example, if the entries of :math:`P` are all strictly positive, then the whole state space is a communication class as well as a recurrent From 5304d2947afe80c1358b69f03fc4a060a23df808 Mon Sep 17 00:00:00 2001 From: Daisuke Oyama Date: Tue, 26 Sep 2017 22:55:36 +0900 Subject: [PATCH 2/2] DOC: Modify docstring --- quantecon/markov/core.py | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/quantecon/markov/core.py b/quantecon/markov/core.py index 4d70125d5..a8815a1e9 100644 --- a/quantecon/markov/core.py +++ b/quantecon/markov/core.py @@ -474,12 +474,8 @@ def simulate_indices(self, ts_length, init=None, num_reps=None, Returns ------- X : ndarray(ndim=1 or 2) - Array containing the sample path(s), of shape (ts_length,) - if init is a scalar (integer) or None and num_reps is None; - of shape (k, ts_length) otherwise, where k = len(init) if - (init, num_reps) = (array, None), k = num_reps if (init, - num_reps) = (int or None, int), and k = len(init)*num_reps - if (init, num_reps) = (array, int). + Array containing the state values of the sample path(s). See + the `simulate` method for more information. """ random_state = check_random_state(random_state) @@ -565,8 +561,12 @@ def simulate(self, ts_length, init=None, num_reps=None, random_state=None): Returns ------- X : ndarray(ndim=1 or 2) - Array containing the state values of the sample path(s). See - the `simulate` method for more information. + Array containing the sample path(s), of shape (ts_length,) + if init is a scalar (integer) or None and num_reps is None; + of shape (k, ts_length) otherwise, where k = len(init) if + (init, num_reps) = (array, None), k = num_reps if (init, + num_reps) = (int or None, int), and k = len(init)*num_reps + if (init, num_reps) = (array, int). """ if init is not None: