Commit c019bd30 authored by Zachary Ware's avatar Zachary Ware

Fix markup, add versionadded tags

parent ffcb0227
...@@ -135,9 +135,11 @@ However, for reading convenience, most of the examples show sorted sequences. ...@@ -135,9 +135,11 @@ However, for reading convenience, most of the examples show sorted sequences.
giving an average growth of 5.385%. Using the arithmetic mean will giving an average growth of 5.385%. Using the arithmetic mean will
give approximately 5.667%, which is too high. give approximately 5.667%, which is too high.
:exc:``StatisticsError`` is raised if *data* is empty, or any :exc:`StatisticsError` is raised if *data* is empty, or any
element is less than zero. element is less than zero.
.. versionadded:: 3.6
.. function:: harmonic_mean(data) .. function:: harmonic_mean(data)
...@@ -145,7 +147,7 @@ However, for reading convenience, most of the examples show sorted sequences. ...@@ -145,7 +147,7 @@ However, for reading convenience, most of the examples show sorted sequences.
real-valued numbers. real-valued numbers.
The harmonic mean, sometimes called the subcontrary mean, is the The harmonic mean, sometimes called the subcontrary mean, is the
reciprocal of the arithmetic :func:``mean`` of the reciprocals of the reciprocal of the arithmetic :func:`mean` of the reciprocals of the
data. For example, the harmonic mean of three values *a*, *b* and *c* data. For example, the harmonic mean of three values *a*, *b* and *c*
will be equivalent to ``3/(1/a + 1/b + 1/c)``. will be equivalent to ``3/(1/a + 1/b + 1/c)``.
...@@ -165,9 +167,11 @@ However, for reading convenience, most of the examples show sorted sequences. ...@@ -165,9 +167,11 @@ However, for reading convenience, most of the examples show sorted sequences.
Using the arithmetic mean would give an average of about 5.167, which Using the arithmetic mean would give an average of about 5.167, which
is too high. is too high.
:exc:``StatisticsError`` is raised if *data* is empty, or any element :exc:`StatisticsError` is raised if *data* is empty, or any element
is less than zero. is less than zero.
.. versionadded:: 3.6
.. function:: median(data) .. function:: median(data)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment