Skip to content

Ensure xplt.FacetGrid works on Dataset objects #613

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

Merged
merged 3 commits into from
Oct 26, 2015

Conversation

shoyer
Copy link
Member

@shoyer shoyer commented Oct 8, 2015

This, along with the .map method, provides a much more generally flexible API for making plots.

It still needs some examples for the docs. Here's something simple with synthetic data:

ds = xray.Dataset({'x': np.linspace(0, 10),
                   'y': [1, 2, 3],
                   'foo': ('x', np.random.randn(50)),
                   'bar': ('x', np.random.rand(50))})
ds *= ds.y
(xplt.FacetGrid(ds, col='y')
 .map(plt.plot, 'x', 'foo')
 .map(plt.scatter, 'x', 'bar', color='green'))

image

@jhamman
Copy link
Member

jhamman commented Oct 8, 2015

This is great. I'll give this a review later today.

Side note: I think we're going to have a few merge conflicts after #608.

@shoyer
Copy link
Member Author

shoyer commented Oct 8, 2015

Yes, this will certainly need a rebase after #608 (which we should merge first).

@shoyer shoyer force-pushed the facet-dataset branch 2 times, most recently from 8251cf9 to 61c2414 Compare October 11, 2015 00:30
This, along with the ``.map`` method, provides a much more generally
flexible API for making plots. It still needs some examples for the docs.
Here's something simple with synthetic data:

    ds = xray.Dataset({'x': np.linspace(0, 10),
                       'y': [1, 2, 3],
                       'foo': ('x', np.random.randn(50)),
                       'bar': ('x', np.random.rand(50))})
    ds *= ds.y
    (xplt.FacetGrid(ds, col='y')
     .map(plt.plot, 'x', 'foo')
     .map(plt.scatter, 'x', 'bar', color='green'))
@shoyer
Copy link
Member Author

shoyer commented Oct 20, 2015

@jhamman any comments here?

@jhamman
Copy link
Member

jhamman commented Oct 21, 2015

@shoyer - I just had a look through this. I don't have any significant comments. I think you merge this.

shoyer added a commit that referenced this pull request Oct 26, 2015
Ensure xplt.FacetGrid works on Dataset objects
@shoyer shoyer merged commit 187a9f7 into pydata:master Oct 26, 2015
@shoyer shoyer deleted the facet-dataset branch October 26, 2015 17:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants