Skip to content

Commit

Permalink
Minor fixes to docstring
Browse files Browse the repository at this point in the history
  • Loading branch information
Prateek Bhustali committed Jul 3, 2022
1 parent 786c6e5 commit af5e2a5
Show file tree
Hide file tree
Showing 6 changed files with 25 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@
Mechanical oscillator model (multioutput)
==============================================
The mechanical oscillator is governed by the following second-order ODE:
In this example, we consider the mechanical oscillator is governed by the following
second-order ODE as demonstrated in [1]_:
.. math::
m \ddot{x} + c \dot{x} + k x = 0
Expand All @@ -20,6 +21,8 @@
parameters at each point in time, the GSI indices summarise the sensitivities of the
model parameters over the entire time period.
.. [1] Gamboa, F., Janon, A., Klein, T., & Lagnoux, A. (2014). Sensitivity analysis for multidimensional and functional outputs. Electronic Journal of Statistics, 8(1), 575-603.
"""

# %%
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
Toy multioutput function
==============================================
In this example, we demonstrate the computation of the Generalised Sobol indices using
the toy example in [1]_.
.. math::
Y = f (X_{1}, X_{2}) := \left(\begin{array}{c}
X_{1}+X_{2}+X_{1} X_{2} \\
Expand All @@ -15,6 +18,8 @@
.. math::
\text{case 2: } X_1, X_2 \sim \mathcal{U}(0, 1)
.. [1] Gamboa, F., Janon, A., Klein, T., & Lagnoux, A. (2014). Sensitivity analysis for multidimensional and functional outputs. Electronic Journal of Statistics, 8(1), 575-603.
"""

# %%
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@
Mechanical oscillator model (multioutput)
==============================================
The mechanical oscillator is governed by the following second-order ODE:
In this example, we consider the mechanical oscillator is governed by the following
second-order ODE as demonstrated in [1]_:
.. math::
m \ddot{x} + c \dot{x} + k x = 0
Expand All @@ -20,6 +21,8 @@
pointwise-in-time Sobol indices. These indices describe the sensitivity of the model
parameters at each point in time.
.. [1] Gamboa, F., Janon, A., Klein, T., & Lagnoux, A. (2014). Sensitivity analysis for multidimensional and functional outputs. Electronic Journal of Statistics, 8(1), 575-603.
"""

# %%
Expand Down
5 changes: 5 additions & 0 deletions docs/code/sensitivity/sobol/plot_sobol_additive.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,14 @@
Additive function
==============================================
We introduce the variance-based Sobol indices using an elementary example.
For more details, refer [1]_.
.. math::
f(x) = a \cdot X_1 + b \cdot X_2, \quad X_1, X_2 \sim \mathcal{N}(0, 1), \quad a,b \in \mathbb{R}
.. [1] Saltelli A, T. (2008). Global sensitivity analysis: The primer. John Wiley.
"""

# %%
Expand Down
5 changes: 5 additions & 0 deletions docs/code/sensitivity/sobol/plot_sobol_func.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,11 @@
.. math::
x_i \sim \mathcal{U}(0, 1), \quad a_i \in \mathbb{R}.
This is an example from [1]_, where first order, total order and additionally the second
order indices are computed.
.. [1] Glen, G., & Isaacs, K. (2012). Estimating Sobol sensitivity indices using correlations. Environmental Modelling and Software, 37, 157–166.
"""

# %%
Expand Down
4 changes: 2 additions & 2 deletions src/UQpy/sensitivity/Chatterjee.py
Original file line number Diff line number Diff line change
Expand Up @@ -101,8 +101,8 @@ def run(
"""
Compute the sensitivity indices using the Chatterjee method.
:param n_samples: Number of samples used to compute the Cramér-von Mises indices. \
Default is 1,000.
:param n_samples: Number of samples used to compute the Chatterjee indices. \
Default is 1,000.
:param estimate_sobol_indices: If :code:`True`, the Sobol indices are estimated \
using the pick-and-freeze samples.
Expand Down

0 comments on commit af5e2a5

Please sign in to comment.