Skip to content

Commit 191259b

Browse files
rhettingermiss-islington
authored andcommitted
gh-154942: Document the kde() data cache logic. (gh-157725)
(cherry picked from commit 5afcd82) Co-authored-by: Raymond Hettinger <rhettinger@users.noreply.github.com>
1 parent bb81bc8 commit 191259b

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

Doc/library/statistics.rst

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -309,6 +309,11 @@ However, for reading convenience, most of the examples show sorted sequences.
309309
.. image:: kde_example.png
310310
:alt: Scatter plot of the estimated probability density function.
311311

312+
Because the returned ``f_hat`` function is typically called many times,
313+
it caches the *data* for performance. To support dynamic datasets, this
314+
cache automatically refreshes whenever the length of the *data* changes.
315+
This allows new samples to be added as they become available.
316+
312317
.. versionadded:: 3.13
313318

314319

0 commit comments

Comments
 (0)