From e5e794b3e794292a0141c6a8dcfcc3e1999e5e42 Mon Sep 17 00:00:00 2001 From: gallowayj Date: Sat, 19 Feb 2022 00:40:05 +0000 Subject: [PATCH 1/2] Updated pymc.GaussianRandomWalk docstring --- pymc/distributions/timeseries.py | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/pymc/distributions/timeseries.py b/pymc/distributions/timeseries.py index 467a73c3e5..cb0ca99d80 100644 --- a/pymc/distributions/timeseries.py +++ b/pymc/distributions/timeseries.py @@ -185,19 +185,19 @@ class GaussianRandomWalk(distribution.Continuous): Parameters ---------- - mu: tensor + mu : TensorVariable, optional innovation drift, defaults to 0.0 - For vector valued mu, first dimension must match shape of the random walk, and + For vector valued `mu`, first dimension must match shape of the random walk, and the first element will be discarded (since there is no innovation in the first timestep) - sigma: tensor - sigma > 0, innovation standard deviation (only required if tau is not specified) - For vector valued sigma, first dimension must match shape of the random walk, and + sigma : TensorVariable, optional + `sigma` > 0, innovation standard deviation (only required if `tau` is not specified) + For vector valued `sigma`, first dimension must match shape of the random walk, and the first element will be discarded (since there is no innovation in the first timestep) - tau: tensor - tau > 0, innovation precision (only required if sigma is not specified) - For vector valued tau, first dimension must match shape of the random walk, and + tau : TensorVariable, optional + `tau` > 0, innovation precision (only required if `sigma` is not specified) + For vector valued `tau`, first dimension must match shape of the random walk, and the first element will be discarded (since there is no innovation in the first timestep) - init: distribution + init : distribution, optional distribution for initial value (Defaults to Flat()) """ @@ -230,7 +230,7 @@ def logp(self, x): Parameters ---------- - x: numeric + x : numeric Value for which log-probability is calculated. Returns @@ -250,10 +250,10 @@ def random(self, point=None, size=None): Parameters ---------- - point: dict, optional + Point : dict, optional Dict of variable values on which random values are to be conditioned (uses default point if not specified). - size: int, optional + size : int, optional Desired size of random sample (returns one sample if not specified). From 13649d09378e52cf34bd2b9a7e92d4afb5ea4a1b Mon Sep 17 00:00:00 2001 From: gallowayj Date: Sat, 19 Feb 2022 21:27:39 +0000 Subject: [PATCH 2/2] Addressed review comments to changes to GWR docstring --- pymc/distributions/timeseries.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/pymc/distributions/timeseries.py b/pymc/distributions/timeseries.py index cb0ca99d80..6691ad2e93 100644 --- a/pymc/distributions/timeseries.py +++ b/pymc/distributions/timeseries.py @@ -185,19 +185,19 @@ class GaussianRandomWalk(distribution.Continuous): Parameters ---------- - mu : TensorVariable, optional + mu : tensor_like of float, default 0 innovation drift, defaults to 0.0 For vector valued `mu`, first dimension must match shape of the random walk, and the first element will be discarded (since there is no innovation in the first timestep) - sigma : TensorVariable, optional + sigma : tensor_like of float, optional `sigma` > 0, innovation standard deviation (only required if `tau` is not specified) For vector valued `sigma`, first dimension must match shape of the random walk, and the first element will be discarded (since there is no innovation in the first timestep) - tau : TensorVariable, optional + tau : tensor_like of float, optional `tau` > 0, innovation precision (only required if `sigma` is not specified) For vector valued `tau`, first dimension must match shape of the random walk, and the first element will be discarded (since there is no innovation in the first timestep) - init : distribution, optional + init : pymc.Distribution, optional distribution for initial value (Defaults to Flat()) """ @@ -250,7 +250,7 @@ def random(self, point=None, size=None): Parameters ---------- - Point : dict, optional + point : dict or Point, optional Dict of variable values on which random values are to be conditioned (uses default point if not specified). size : int, optional