-
-
Notifications
You must be signed in to change notification settings - Fork 7.9k
DOC: add links to examples for a few examples #11019
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
Conversation
66b0934
to
ce25253
Compare
this is such a good idea. |
All credit goes to @ImportanceOfBeingErnest for the good idea! Given that this has some approval, I'll toss a few of these in every few days just to build up the galleries. (and others should as well if they feel like it). |
@meeseeksdev backport to v2.2-doc |
Something went wrong ... Please have a look at my logs. |
@meeseeksdev backport to v2.2.2-doc |
I fear if everyone just updates a few examples at random, this will become great chaos. So if, as it seems to be the case, there is general agreement for this method, I would say there should be an attempt to do this with all examples. I think that all examples are actually part of the gallery. Is that correct? The gallery is divided into sections. There could be one Issue with a table of all sections and next to it an assignee and a "completed" flag. If someone wants to contribute they'd anounce it in that Issue and gets his name written next to the section. He could then open the PR and once completed, mark as such in the main issue. |
It's nice to keep track of things like that. But in general, we don't have problems with "everyone" or even "more than a handful of people" trying to do the same thing. If you look at the first few pages of PRs, it's a pretty small |
My suggestion was all about keeping track, indeed. Maybe you don't care if two or more people end up doing the exact same work, but it is sure frustrating for those people finding out that they could have spend their time doing more useful things if they had only known that someone else is working on the same thing at the same time. There is a new-contributor-friendly label or so which could invite people to join this effort. |
I wasn't aiming for anything so comprehensive, but if someone wants to lead the charge I'd comply. I just thought of trying to do a critical mass of these so folks realize they are a thing to do, and then let the examples be updated as they come up or as folks have energy. @ImportanceOfBeingErnest if you were thinking of a) organizing a full-on effort to do this, I'd be happy to participate, or b) were going to poke away at it yourself, then the two of us could co-ordinate (like you start at "A" and I start at "Z"). |
Backport PR #11019 on branch v2.2.2-doc
@ImportanceOfBeingErnest I'm doing something similar for the docstrings in #10148. The main advantage of such a list is to keep track of what has been done and what still needs to be done. Duplicated work is less of a problem since each change is comparably small and can be commited quite soon. Of course, if someone wants to reserve a block to work on he can mark that in the list. |
PR Summary
Following the suggestion in #10974 by @ImportanceOfBeingErnest , this PR adds a "References" sections to a few randomly chosen examples. This should form links in the API docs to the examples.
The only disadvantage to this approach that I can see is that we have to
import matplotlib
for the examples to still work.This isn't meant to be comprehensive (at all) but following this approach for future examples and modified examples would greatly increase the cross-referencing between examples and API docs...
The code to include is
plot
https://8868-1385122-gh.circle-artifacts.com/0/home/circleci/project/doc/build/html/api/_as_gen/matplotlib.axes.Axes.plot.html#examples-using-matplotlib-axes-axes-plot
pcolormesh:
https://8868-1385122-gh.circle-artifacts.com/0/home/circleci/project/doc/build/html/api/_as_gen/matplotlib.axes.Axes.pcolormesh.html#matplotlib.axes.Axes.pcolormesh
scatter:
https://8868-1385122-gh.circle-artifacts.com/0/home/circleci/project/doc/build/html/api/_as_gen/matplotlib.axes.Axes.scatter.html#matplotlib.axes.Axes.scatter
hist
https://8868-1385122-gh.circle-artifacts.com/0/home/circleci/project/doc/build/html/api/_as_gen/matplotlib.axes.Axes.hist.html#matplotlib.axes.Axes.hist