@@ -14,68 +14,70 @@ Values are computed upon request.
1414Ones and zeros
1515--------------
1616
17- - `` zeros(shape) ` `: generates an expression containing zeros of the specified shape.
18- - `` ones(shape) ` `: generates an expression containing ones of the specified shape.
19- - `` eye(shape, k=0) ` `: generates an expression of the specified shape, with ones on the k-th diagonal.
20- - `` eye(n, k = 0) ` `: generates an expression of shape ``(n, n) `` with ones on the k-th diagonal.
17+ - :cpp:func: ` xt:: zeros(shape) <xt::zeros> `: generates an expression containing zeros of the specified shape.
18+ - :cpp:func: ` xt:: ones(shape) <xt::ones> `: generates an expression containing ones of the specified shape.
19+ - :cpp:func: ` xt:: eye(shape, k=0) <xt::eye> `: generates an expression of the specified shape, with ones on the k-th diagonal.
20+ - :cpp:func: ` xt:: eye(n, k = 0) <xt::eye> `: generates an expression of shape ``(n, n) `` with ones on the k-th diagonal.
2121
2222Numerical ranges
2323----------------
2424
25- - `` arange(start=0, stop, step=1) ` `: generates numbers evenly spaced within given half-open interval.
26- - `` linspace(start, stop, num_samples) ` `: generates num_samples evenly spaced numbers over given interval.
27- - `` logspace(start, stop, num_samples) ` `: generates num_samples evenly spaced on a log scale over given interval
25+ - :cpp:func: ` xt:: arange(start=0, stop, step=1) <xt::arange> `: generates numbers evenly spaced within given half-open interval.
26+ - :cpp:func: ` xt:: linspace(start, stop, num_samples) <xt::linspace> `: generates num_samples evenly spaced numbers over given interval.
27+ - :cpp:func: ` xt:: logspace(start, stop, num_samples) <xt::logspace> `: generates num_samples evenly spaced on a log scale over given interval
2828
2929Joining expressions
3030-------------------
3131
32- - `` concatenate(tuple, axis=0) ` `: concatenates a list of expressions along the given axis.
33- - `` stack(tuple, axis=0) ` `: stacks a list of expressions along the given axis.
34- - `` hstack(tuple) ` `: stacks expressions in sequence horizontally (i.e. column-wise).
35- - `` vstack(tuple) ` `: stacks expressions in sequence vertically (i.e. row wise).
32+ - :cpp:func: ` xt:: concatenate(tuple, axis=0) <xt::concatenate> `: concatenates a list of expressions along the given axis.
33+ - :cpp:func: ` xt:: stack(tuple, axis=0) <xt::stack> `: stacks a list of expressions along the given axis.
34+ - :cpp:func: ` xt:: hstack(tuple) <xt::hstack> `: stacks expressions in sequence horizontally (i.e. column-wise).
35+ - :cpp:func: ` xt:: vstack(tuple) <xt::vstack> `: stacks expressions in sequence vertically (i.e. row wise).
3636
3737Random distributions
3838--------------------
3939
40- .. warning :: xtensor uses a lazy generator for random numbers. You need to assign them or use ``eval`` to keep the generated values consistent.
41-
42- - ``rand(shape, lower, upper) ``: generates an expression of the specified shape, containing uniformly
43- distributed random numbers in the half-open interval [lower, upper).
44- - ``randint(shape, lower, upper) ``: generates an expression of the specified shape, containing uniformly
45- distributed random integers in the half-open interval [lower, upper).
46- - ``randn(shape, mean, std_dev) ``: generates an expression of the specified shape, containing numbers
47- sampled from the Normal random number distribution.
48- - ``binomial(shape, trials, prob) ``: generates an expression of the specified shape, containing numbers
49- sampled from the binomial random number distribution.
50- - ``geometric(shape, prob) ``: generates an expression of the specified shape, containing numbers
51- sampled from the geometric random number distribution.
52- - ``negative_binomial(shape, k, prob) ``: generates an expression of the specified shape, containing numbers
53- sampled from the negative binomial random number distribution.
54- - ``poisson(shape, rate) ``: generates an expression of the specified shape, containing numbers
55- sampled from the Poisson random number distribution.
56- - ``exponential(shape, rate) ``: generates an expression of the specified shape, containing numbers
57- sampled from the exponential random number distribution.
58- - ``gamma(shape, alpha, beta) ``: generates an expression of the specified shape, containing numbers
59- sampled from the gamma random number distribution.
60- - ``weibull(shape, a, b) ``: generates an expression of the specified shape, containing numbers
61- sampled from the Weibull random number distribution.
62- - ``extreme_value(shape, a, b) ``: generates an expression of the specified shape, containing numbers
63- sampled from the extreme value random number distribution.
64- - ``lognormal(shape, a, b) ``: generates an expression of the specified shape, containing numbers
65- sampled from the Log-Normal random number distribution.
66- - ``chi_squared(shape, a, b) ``: generates an expression of the specified shape, containing numbers
67- sampled from the chi-squared random number distribution.
68- - ``cauchy(shape, a, b) ``: generates an expression of the specified shape, containing numbers
69- sampled from the Cauchy random number distribution.
70- - ``fisher_f(shape, m, n) ``: generates an expression of the specified shape, containing numbers
71- sampled from the Fisher-f random number distribution.
72- - ``student_t(shape, n) ``: generates an expression of the specified shape, containing numbers
73- sampled from the Student-t random number distribution.
40+ .. warning :: xtensor uses a lazy generator for random numbers.
41+ You need to assign them or use :cpp:func: `xt::eval ` to keep the generated values consistent.
42+
43+ - :cpp:func: `xt::random::rand(shape, lower, upper) <xt::random::rand> `: generates an expression of the specified
44+ shape, containing uniformly distributed random numbers in the half-open interval [lower, upper).
45+ - :cpp:func: `xt::random::randint(shape, lower, upper) <xt::random::randint> `: generates an expression of the specified
46+ shape, containing uniformly distributed random integers in the half-open interval [lower, upper).
47+ - :cpp:func: `xt::random::randn(shape, mean, std_dev) <xt::random::randn> `: generates an expression of the specified
48+ shape, containing numbers sampled from the Normal random number distribution.
49+ - :cpp:func: `xt::random::binomial(shape, trials, prob) <xt::random::binomial> `: generates an expression of the specified
50+ shape, containing numbers sampled from the binomial random number distribution.
51+ - :cpp:func: `xt::random::geometric(shape, prob) <xt::random::geometric> `: generates an expression of the specified shape,
52+ containing numbers sampled from the geometric random number distribution.
53+ - :cpp:func: `xt::random::negative_binomial(shape, k, prob) <xt::random::negative_binomial> `: generates an expression
54+ of the specified shape, containing numbers sampled from the negative binomial random number distribution.
55+ - :cpp:func: `xt::random::poisson(shape, rate) <xt::random::poisson> `: generates an expression of the specified shape,
56+ containing numbers sampled from the Poisson random number distribution.
57+ - :cpp:func: `xt::random::exponential(shape, rate) <xt::random::exponential> `: generates an expression of the specified
58+ shape, containing numbers sampled from the exponential random number distribution.
59+ - :cpp:func: `xt::random::gamma(shape, alpha, beta) <xt::random::gamma> `: generates an expression of the specified shape,
60+ containing numbers sampled from the gamma random number distribution.
61+ - :cpp:func: `xt::random::weibull(shape, a, b) <xt::random::weibull> `: generates an expression of the specified shape,
62+ containing numbers sampled from the Weibull random number distribution.
63+ - :cpp:func: `xt::random::extreme_value(shape, a, b) <xt::random::extreme_value> `: generates an expression of the
64+ specified shape, containing numbers sampled from the extreme value random number distribution.
65+ - :cpp:func: `xt::random::lognormal(shape, a, b) <xt::random::lognormal> `: generates an expression of the specified
66+ shape, containing numbers sampled from the Log-Normal random number distribution.
67+ - :cpp:func: `xt::random::chi_squared(shape, a, b) <xt::random::chi_squared> `: generates an expression of the specified
68+ shape, containing numbers sampled from the chi-squared random number distribution.
69+ - :cpp:func: `xt::random::cauchy(shape, a, b) <xt::random::cauchy> `: generates an expression of the specified shape,
70+ containing numbers sampled from the Cauchy random number distribution.
71+ - :cpp:func: `xt::random::fisher_f(shape, m, n) <xt::random::fisher_f> `: generates an expression of the specified shape,
72+ containing numbers sampled from the Fisher-f random number distribution.
73+ - :cpp:func: `xt::random::student_t(shape, n) <xt::random::student_t> `: generates an expression of the specified shape,
74+ containing numbers sampled from the Student-t random number distribution.
7475
7576Meshes
7677------
7778
78- - ``meshgrid(x1, x2,...)` ``: generates N-D coordinate expressions given one-dimensional coordinate arrays ``x1 ``, ``x2 ``...
79+ - :cpp:func: `xt::meshgrid(x1, x2,...) <xt::meshgrid> `: generates N-D coordinate expressions given
80+ one-dimensional coordinate arrays ``x1 ``, ``x2 ``...
7981 If specified vectors have lengths ``Ni = len(xi) ``, meshgrid returns ``(N1, N2, N3,..., Nn) ``-shaped arrays, with the elements
8082 of xi repeated to fill the matrix along the first dimension for x1, the second for x2 and so on.
8183
0 commit comments