-
-
Notifications
You must be signed in to change notification settings - Fork 7.9k
DOC: add new showcase example, replace gendered one #23365
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
DOC: add new showcase example, replace gendered one #23365
Conversation
3fa814f
to
a30c94c
Compare
examples/showcase/stock_prices.py
Outdated
Stock prices over 32 years | ||
========================== | ||
|
||
.. redirect-from:: /gallery/showcase/backelor_degrees_by_gender |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
.. redirect-from:: /gallery/showcase/backelor_degrees_by_gender | |
.. redirect-from:: /gallery/showcase/bachelors_degrees_by_gender |
examples/showcase/stock_prices.py
Outdated
'#e377c2', '#f7b6d2', '#7f7f7f', '#c7c7c7', '#bcbd22', '#dbdb8d', | ||
'#17becf', '#9edae5']) | ||
|
||
# 'AMZN', 'DELL', 'GOOGL', 'ADBE', '^GSPC', '^IXIC'] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
?
examples/showcase/stock_prices.py
Outdated
# is adding specific offsets y position because some labels overlapped. | ||
y_pos = stock_data[column][-1] | ||
|
||
# use an offset transform, in points, for any text that needs to be nudged |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
# use an offset transform, in points, for any text that needs to be nudged | |
# Use an offset transform, in points, for any text that needs to be nudged |
examples/showcase/stock_prices.py
Outdated
stocks_ticker = ['IBM', 'AAPL', 'MSFT', 'XRX', 'AMZN', 'DELL', 'GOOGL', | ||
'ADBE', 'GSPC', 'IXIC'] | ||
|
||
# manually adjust the label positions vertically (units are points = 1/72 inch) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
# manually adjust the label positions vertically (units are points = 1/72 inch) | |
# Manually adjust the label positions vertically (units are points = 1/72 inch). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some minor nit-picks (but the redirect is relevant to change).
And a good idea to change this! (I think there are some other examples with a similar subject.)
…kip azp] [skip appveyor]
a30c94c
to
cac2bc6
Compare
Yes for sure. I thought those would be easy as a good first issue, but this one was a bit more involved: |
Can we please hold on merging this for a bit? |
I moved to draft, but just to be clear
|
(sorry, accidentally posted a half-written message which I deleted) I had not realized that we did not have a citation on the underlying data. Although I trust that this data come to us in good faith, the lack of provenance is enough to convince me that we should change the example. I do not think it is a good use of our time to track down (and evaluate) the source of the original data. The DEI issues in STEM are obvious and far (far) larger than Matplotlib. We should focus on making sure we are an open welcoming project that treats everyone who comes to us with respect and professionalism to enable them to contribute as they have ability and desire. The contents of an example that is, in the best case, a distraction. |
There was (offline) discussion about this before it was merged, I should have made that clear. I have since learned (via @noatamir and @melissawm ) the data is likely from https://www.npr.org/sections/money/2014/10/21/357629765/when-women-stopped-coding / https://www.nsf.gov/statistics/nsf13327/content.cfm?pub_id=4266&id=2 . |
PR Summary
We really don't need to have examples that refer to gender like: https://matplotlib.org/stable/gallery/showcase/bachelors_degrees_by_gender.html. Replace it by this example.. I cleaned up some of the example, which was doing a lot of unnecessary manual futzing, but I left some of it in.
PR Checklist
Tests and Styling
pytest
passes).flake8-docstrings
and runflake8 --docstring-convention=all
).Documentation
doc/users/next_whats_new/
(follow instructions in README.rst there).doc/api/next_api_changes/
(follow instructions in README.rst there).