Skip to content
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

Make the explorer easier to use #799

Merged
merged 41 commits into from
Aug 12, 2022
Merged

Make the explorer easier to use #799

merged 41 commits into from
Aug 12, 2022

Conversation

maximlt
Copy link
Member

@maximlt maximlt commented Jul 26, 2022

Fixes #764
Fixes #787

  • Should the accessors be patched by default when hvplot.explorer is called? I think so. I changed my mind, less side effects are better, at least for a start.
  • Should the explorer allow to switch the plotting backend? I'm not sure. Let's keep it simple for now.
  • Discuss and extend the API
  • Add tests
  • Add docs. I suggest marking the explorer as experimental on its doc page.

image

@philippjfr in 87b07b4 I've removed the __new__ methods. They were causing __init__ to be called twice, which wasn't really an issue as far as I could tell but was for sure undesired. I found no way to fix that by keeping them, so replaced them by a factory class method from_data that I use in the explorer function. This is a breaking change, which might be fine given that the explorer has been released recently and never documented. If this breaking change is unwanted, I could add a warning when an explorer isn't instantiated with from_data, or keep digging to try to fix the issue with __new__.

@philippjfr
Copy link
Member

Will probably look into the __new__ issue myself. Please remind me when this is otherwise ready.

@maximlt
Copy link
Member Author

maximlt commented Aug 4, 2022

@philippjfr this is ready to be reviewed, if you want to have a look into __new__.

@maximlt
Copy link
Member Author

maximlt commented Aug 5, 2022

Made a few changes after some discussion:

  • Raise an error when the data type given to hvplot.explorer is a geodataframe or an xarray object. This is because I found their support not good enough to be shared.
  • Similarly the Geo tab has been removed, it did not work quite well from what we've seen (e.g.Enhancement to Geo tab in explorer #810)
  • renamed the repr method to plot_code, repr was misleading
  • improved the docs in general

@hoxbro
Copy link
Member

hoxbro commented Aug 5, 2022

If #810 is not expected to be in the next release, can you add these changes to this PR?

@maximlt
Copy link
Member Author

maximlt commented Aug 12, 2022

@philippjfr do you still want to have a look at the __new__ thing or can I merge?

@philippjfr
Copy link
Member

Go ahead and merge, __new__ hackery is usually ugly and unexpected so I'm fine with the current approach.

@philippjfr
Copy link
Member

Thanks for your great work here!

@philippjfr philippjfr merged commit c40d8c3 into master Aug 12, 2022
@philippjfr philippjfr deleted the explorer_api branch August 12, 2022 11:48
@hoxbro hoxbro restored the explorer_api branch September 13, 2023 10:23
@hoxbro hoxbro deleted the explorer_api branch September 13, 2023 10:48
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.

Add options for saving hvPlotExplorer settings and only show the plot Improve the API of the hvPlotExplorer
3 participants