Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

changes for MEP12/sphinx-gallery compliance#8209

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Closed
yinleon wants to merge4 commits intomatplotlib:masterfromyinleon:master

Conversation

yinleon
Copy link
Contributor

Regarding#7206

@tacaswelltacaswell added this to the2.0.1 (next bug fix release) milestoneMar 7, 2017
@@ -1,4 +1,8 @@
"""
===========
Poly Editor
==========
Copy link
Member

Choose a reason for hiding this comment

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

missing '='

# A class that will downsample the data and recompute when zoomed.
class DataDisplayDownsampler(object):
def __init__(self, xdata, ydata):
self.origYData = ydata
self.origXData = xdata
self.ratio =5
self.ratio =50
Copy link
Member

Choose a reason for hiding this comment

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

This seems a bit too aggressive.

@tacaswell
Copy link
Member

Left 2 small comments, but otherwise looks good!

@tacaswell
Copy link
Member

In the future, it is better to make PRs against some branchother than your master branch.

@yinleon
Copy link
ContributorAuthor

@tacaswell will do! My first commit to an OSS project, so apologies.

ax.axis[direction].set_visible(True)

for direction in ["left", "right", "bottom", "top"]:
# hides boarders
Copy link
Member

Choose a reason for hiding this comment

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

boarders -> borders


A matplotlib based game of Pong illustrating one way to write interactive animation which are easily ported to multiple backends pipong.py was written by Paul Ivanov <http://pirsquared.org>
Copy link
Member

Choose a reason for hiding this comment

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

matplotlib -> Matplotlib
animation -> animations
Add period at end of sentence.

Also, please wrap this line at 79 characters.

Resampling Data
===============

Downsampling lowers the sample rate or sample size of a signal. In this tutorial, the signal is downsampled when the plot is adjusted through dragging and zooming.
Copy link
Member

Choose a reason for hiding this comment

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

Wrap this line.

Demonstrate the mixing of 2d and 3d subplots.
============================================
Demonstrate the mixing of 2d and 3d subplots
============================================
Copy link
Member

Choose a reason for hiding this comment

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

Missing blank line after, I think.

Copy link
ContributorAuthor

Choose a reason for hiding this comment

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

I think I resolved this?

=================

This is an example of creating a stacked bar plot with error bars using `plt.bar`.
Note the parameters `yerr` used for error bars, and `bottom` to stack the women's bars on top of the men's bars.
Copy link
Member

@QuLogicQuLogicMar 7, 2017
edited
Loading

Choose a reason for hiding this comment

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

Lines need to be wrapped.

@@ -1,3 +1,11 @@
"""
=======
Dophins
Copy link
Member

Choose a reason for hiding this comment

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

Dophins -> Dolphins

Dophins
=======

This example shows how to draw, and manipulate shapes given verticies and nodes using the patches, path and transforms classes.
Copy link
Member

Choose a reason for hiding this comment

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

Wrap line.

Filling the area between lines
==============================

This example shows how to use fill_between() to color between lines based on user-defined logic.
Copy link
Member

Choose a reason for hiding this comment

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

Wrap line.

======================

This shows 4 possible projections using subplot.
Matplotlib also supports the <a href='http://matplotlib.org/basemap/'>Basemaps Toolkit</a> for geographic projections.
Copy link
Member

Choose a reason for hiding this comment

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

Wrap line. Probably should mention Cartopy as well.

MRI
===

This example illustrates how to read an image (of an MRI) into a numpy array, and display it in greyscale using `ax.imshow`.
Copy link
Member

Choose a reason for hiding this comment

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

numpy -> NumPy

Wrap line.

ax.axis[direction].set_visible(True)

for direction in ["left", "right", "bottom", "top"]:
# hides boarders
Copy link
Contributor

Choose a reason for hiding this comment

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

borders

# pipong.py was written by Paul Ivanov <http://pirsquared.org>
"""
====
PONG
Copy link
Contributor

Choose a reason for hiding this comment

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

"Pong" (I don't think it should be all caps).

@@ -1,3 +1,11 @@
"""
=======
Dophins
Copy link
Contributor

Choose a reason for hiding this comment

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

dolphins

@@ -1,3 +1,10 @@
"""
================
Axis Line Styles
Copy link
Contributor

Choose a reason for hiding this comment

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

Looks like most already converted examples only capitalize the first word (which I prefer too), so let's stay consistent (applies to this and all files below).

Demonstrate the mixing of 2d and 3d subplots.
============================================
Demonstrate the mixing of 2d and 3d subplots
============================================
Copy link
Contributor

Choose a reason for hiding this comment

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

blank line

Copy link
ContributorAuthor

Choose a reason for hiding this comment

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

I think I resolved this?


A matplotlib based game of Pong illustrating one way to write interactive animation which are easily ported to multiple backends pipong.py was written by Paul Ivanov <http://pirsquared.org>
Copy link
Contributor

Choose a reason for hiding this comment

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

Here and below, wrap your lines at 79 characters (most editors should provide some option to help that).

Copy link
Contributor

Choose a reason for hiding this comment

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

Here and below, use the rst syntax for hyperlinks (http://www.sphinx-doc.org/en/stable/rest.html#hyperlinks).

Filling the area between lines
==============================

This example shows how to use fill_between() to color between lines based on user-defined logic.
Copy link
Contributor

Choose a reason for hiding this comment

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

`fill_between`

(with backquotes) -- ultimately this should create a link to the API docs.

Dophins
=======

This example shows how to draw, and manipulate shapes given verticies and nodes using the patches, path and transforms classes.
Copy link
Contributor

Choose a reason for hiding this comment

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

"vertices".

Please spell-check your docstrings.

MRI
===

This example illustrates how to read an image (of an MRI) into a numpy array, and display it in greyscale using `ax.imshow`.
Copy link
Contributor

Choose a reason for hiding this comment

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

justimshow

@anntzer
Copy link
Contributor

Apparently I reviewed this at the same time as@QuLogic :-)

@tacaswell
Copy link
Member

Apparently other reviewer can spell better than I can..

@yinleon
Copy link
ContributorAuthor

thanks@anntzer and@QuLogic, you two are equally thorough :)


A Matplotlib based game of Pong illustrating one way to write interactive
animations which are easily ported to multiple backends pipong.py was written
by <a href='http://pirsquared.org'>Paul Ivanov</a>.
Copy link
Member

Choose a reason for hiding this comment

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

I am somewhat not surprised by the original author of that example…
ping@ivanov :D

@yinleon
Copy link
ContributorAuthor

should I be alarmed about the Travis CLI failure? Now sure I understand what I'm seeing under Details.

Pong
====

A Matplotlib based game of Pong illustrating one way to write interactive
Copy link
Contributor

Choose a reason for hiding this comment

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

Beware of the trailing whitespace (remove it for PEP8-compliance)

====

A Matplotlib based game of Pong illustrating one way to write interactive
animations which are easily ported to multiple backends pipong.py was written
Copy link
Contributor

Choose a reason for hiding this comment

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

As above, just remove the trailing whitespace for PEP8-compliance

@afvincent
Copy link
Contributor

afvincent commentedMar 7, 2017
edited
Loading

The Travis failure is related to PEP8 (more precisely to two trailing whitespaces). More detailshere ;).

Edit: typo

@QuLogic
Copy link
Member

If you have changes to multiple files, editing on GitHub is not a good choice. It creates way too many single commits of one or two minor changes. Please rebase and squash this on your local copy if you can.

@NelleV
Copy link
Member

NelleV commentedMar 8, 2017
edited
Loading

Can we activate the squash and merge option? This would allow us to squash and merge before merging instead of asking contributors to rebase themselves.

ping@tacaswell

@QuLogic
Copy link
Member

QuLogic commentedMar 8, 2017
edited
Loading

TBH, as acontributor, I don't really like squash&merge as it decouples your fork and upstream's (I don't like rebase&merge for the same reason.)

tacaswell reacted with thumbs up emoji

@yinleon
Copy link
ContributorAuthor

Hi, I squashed all 20 commits. Did I do it correctly? Is it reflected in this PR, or should I make a new one?

NelleV reacted with thumbs up emoji

@NelleV
Copy link
Member

Yep, it is done and it works! Thanks!

@NelleVNelleV changed the titlechanges for MEP12/sphinx-gallery compliance[MRG+] changes for MEP12/sphinx-gallery complianceMar 8, 2017
@NelleVNelleV changed the title[MRG+] changes for MEP12/sphinx-gallery compliance[MRG+1] changes for MEP12/sphinx-gallery complianceMar 8, 2017
Copy link
Member

@NelleVNelleV left a comment

Choose a reason for hiding this comment

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

LGTM 👍

@QuLogic
Copy link
Member

QuLogic commentedMar 8, 2017
edited
Loading

Hi, I squashed all 20 commits. Did I do it correctly? Is it reflected in this PR, or should I make a new one?

No, it's not quite right. After rebasing, you need to force push the result. If you don't force, git will complain and suggest you pull everything, but that will restore all the previous commits locally and add another merge commit.

So, please do the rebase, and then dogit push --force origin master (btw, it's safer to use a feature branch instead ofmaster) so that you canreplace all the old commits.

@NelleV
Copy link
Member

@yinleon Are you still around Berkeley? I was mistaken and something didn't quite happen right with the rebase. I am happy to help you out with this tomorrow (I should be at BIDS all afternoon if you are around).

@yinleon
Copy link
ContributorAuthor

Sure thing@QuLogic.
@NelleV yes-- I will be at BIDS tomorrow.
Sorry for the confusion all.

ax.axis[direction].set_axisline_style("-|>")

Copy link
Member

Choose a reason for hiding this comment

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

There is some whitespace here causing the pep8 failure.

@NelleV
Copy link
Member

Hi@yinleon
There was a small blank line issue, that I fixed.

This patch needs an additional review.

@NelleVNelleV added the MEP: MEP12gallery and examples improvements labelMar 11, 2017
Copy link
Member

@QuLogicQuLogic left a comment

Choose a reason for hiding this comment

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

LGTM, but can you amend this last typo,@NelleV?

matplotlib event handling to interact with objects on the canvas
===========
Poly Editor
==========
Copy link
Member

Choose a reason for hiding this comment

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

One missing=.

@NelleVNelleV changed the title[MRG+1] changes for MEP12/sphinx-gallery compliance[MRG+2] changes for MEP12/sphinx-gallery complianceMar 12, 2017
@NelleV
Copy link
Member

I think this is ready to be merged.@anntzer can you have a look at this?

====

A Matplotlib based game of Pong illustrating one way to write interactive
animations which are easily ported to multiple backends pipong.py was written
Copy link
Contributor

Choose a reason for hiding this comment

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

dot after "multiple backends"


A Matplotlib based game of Pong illustrating one way to write interactive
animations which are easily ported to multiple backends pipong.py was written
by <a href='http://pirsquared.org'>Paul Ivanov</a>.
Copy link
Contributor

Choose a reason for hiding this comment

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


This is an example of plotting Edward Lorenz's 1963 "Deterministic
Nonperiodic Flow" in a 3-dimensional space using mplot3d.

Copy link
Contributor

Choose a reason for hiding this comment

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

=================

This is an example of creating a stacked bar plot with error bars using
`plt.bar`. Note the parameters `yerr` used for error bars, and `bottom`
Copy link
Contributor

Choose a reason for hiding this comment

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

yerr and bottom should use*foo*, not backticks (they are not references to linkable elements).

========

This example shows how to draw, and manipulate shapes given vertices and nodes
using the `patches`, `path` and `transforms` classes.
Copy link
Contributor

Choose a reason for hiding this comment

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

Patch,Path, andTransform (references to actual python names).


This shows 4 possible projections using subplot.
Matplotlib also supports
<a href='http://matplotlib.org/basemap/'>Basemaps Toolkit</a> and
Copy link
Contributor

Choose a reason for hiding this comment

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

same comment as above regarding hyperlink syntax (either way works).

@dstansbydstansby self-assigned thisApr 12, 2017
@dstansby
Copy link
Member

This is going to take a bit of a rebase now sphinx-gallery is merged. I've assigned this to myself and will try to do it in the next day or so.

@choldgraf
Copy link
Contributor

hey@yinleon , a lot has changed with MPL docs in the last few weeks :)

This means it'll be a bit more complicated to get this merged. Do you have time to do a live skype where you and I can spot-check these issues and get it back to a mergeable state?

@dstansby
Copy link
Member

So I actually had a go at rebasing this last night, and gave up after a while. Quite a lot of the changes have already been made (titles), and there's only a couple of things that are now new unfortunately.

I think the easiest thing to do here would be to manually compare the PR diff and the current files, and just copy across anything new.

@choldgraf
Copy link
Contributor

@phobson I think that's a good idea - let's see if@yinleon is interested in finishing this up and then we can make a plan from there

@QuLogicQuLogic modified the milestones:2.0.1 (next bug fix release),2.0.2 (next bug fix release)May 3, 2017
@tacaswelltacaswell mentioned this pull requestJul 10, 2017
@tacaswell
Copy link
Member

Closing in favor of#8860

@QuLogicQuLogic modified the milestones:2.1 (next point release),2.0.3 (next bug fix release)Jul 15, 2017
@QuLogicQuLogic changed the title[MRG+2] changes for MEP12/sphinx-gallery compliancechanges for MEP12/sphinx-gallery complianceJul 15, 2017
@dstansbydstansby removed their assignmentJul 31, 2017
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

@tacaswelltacaswelltacaswell left review comments

@afvincentafvincentafvincent left review comments

@anntzeranntzeranntzer requested changes

@NelleVNelleVNelleV approved these changes

@QuLogicQuLogicQuLogic approved these changes

Assignees
No one assigned
Labels
DocumentationMEP: MEP12gallery and examples improvements
Projects
None yet
Milestone
v2.1
Development

Successfully merging this pull request may close these issues.

8 participants
@yinleon@tacaswell@anntzer@afvincent@QuLogic@NelleV@dstansby@choldgraf

[8]ページ先頭

©2009-2025 Movatter.jp