Skip to content

Update the NaN example output in the statistics docs - #162729

Merged
picnixz merged 1 commit into
python:mainfrom
AlexxRussell:doc-statistics-nan
Nov 27, 2026
Merged

picnixz merged 1 commit into
python:mainfrom
AlexxRussell:doc-statistics-nan

Conversation

@AlexxRussell

Copy link
Copy Markdown
Contributor

The NaN example in the introduction of the statistics docs shows [20.7, nan, 14.4, 18.3, 19.2, nan] for sorted(data) and 16.35 for median(data). That is what 3.9, 3.11 and 3.12 print. On 3.13, 3.14 and main, sorted(data) returns [18.3, nan, 14.4, 20.7, nan, 19.2] and median(data) returns 17.55.

Trivial docs fix, so no issue.

@read-the-docs-community

Copy link
Copy Markdown

Documentation build overview

📚 cpython-previews | 🛠️ Build #36208302 | 📁 Comparing 6941e52 against main (cc00dde)

  🔍 Preview build  

1 file changed
± library/statistics.html

@picnixz picnixz added skip issue needs backport to 3.14 bugs and security fixes needs backport to 3.15 bugs and security fixes labels Nov 27, 2026

@picnixz picnixz left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can confirm the behavior.

@picnixz
picnixz merged commit 8d4c96e into python:main Nov 27, 2026
47 checks passed
@github-project-automation github-project-automation Bot moved this from Todo to Done in Docs PRs Nov 27, 2026
@miss-islington-app

Copy link
Copy Markdown

Thanks @AlexxRussell for the PR, and @picnixz for merging it 🌮🎉.. I'm working now to backport this PR to: 3.14, 3.15.
🐍🍒⛏🤖 I'm not a witch! I'm not a witch!

@bedevere-app

bedevere-app Bot commented Nov 27, 2026

Copy link
Copy Markdown

GH-162734 is a backport of this pull request to the 3.15 branch.

@bedevere-app bedevere-app Bot removed the needs backport to 3.15 bugs and security fixes label Nov 27, 2026
@bedevere-app

bedevere-app Bot commented Nov 27, 2026

Copy link
Copy Markdown

GH-162735 is a backport of this pull request to the 3.14 branch.

@bedevere-app bedevere-app Bot removed the needs backport to 3.14 bugs and security fixes label Nov 27, 2026
picnixz pushed a commit that referenced this pull request Nov 27, 2026
) (#162735)

Update the NaN example output in the `statistics` docs (GH-162729)
(cherry picked from commit 8d4c96e)

Co-authored-by: Alexander R <alex-secure@tuta.io>
picnixz pushed a commit that referenced this pull request Nov 27, 2026
) (#162734)

Update the NaN example output in the `statistics` docs (GH-162729)
(cherry picked from commit 8d4c96e)

Co-authored-by: Alexander R <alex-secure@tuta.io>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

docs Documentation in the Doc dir skip issue skip news

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

2 participants