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

Clarify clip filter docstring #840

Merged
merged 4 commits into from
Jul 23, 2020
Merged

Conversation

MatthewFlamm
Copy link
Contributor

Overview

The clip filter docstring currently states that "If no parameters are given the clip will occur in the center of that dataset." However it isn't really clear why this is true from the defaults of the other parameters. What if I specify just the value? Adding this to the description of origin clarifies this.

The description of value seems to be held over from somewhere else, which is also fixed.

Additionally, I made an edit for consistency (within clip anyway) to end with a period, but I see both styles in other docstrings in this module.

Details

I didn't make any changes, but there is inconsistent usage of optional. Specifying the default value in the parameter description is also inconsistent throughout the filters. I wasn't sure what is preferred for further cleaning up the clip filter docstring.

pyvista/core/filters.py Outdated Show resolved Hide resolved
pyvista/core/filters.py Outdated Show resolved Hide resolved
pyvista/core/filters.py Outdated Show resolved Hide resolved
Copy link
Member

@akaszynski akaszynski left a comment

Choose a reason for hiding this comment

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

This is much cleaner, thanks!

Consider my suggestions when merging.

MatthewFlamm and others added 3 commits July 17, 2020 15:58
Co-authored-by: Alex Kaszynski <akascap@gmail.com>
Co-authored-by: Alex Kaszynski <akascap@gmail.com>
Co-authored-by: Alex Kaszynski <akascap@gmail.com>
@MatthewFlamm
Copy link
Contributor Author

Thanks for clarifying what is intended.

@banesullivan banesullivan added the documentation Anything related to the documentation/website label Jul 17, 2020
@akaszynski akaszynski merged commit ae6fb09 into pyvista:master Jul 23, 2020
@akaszynski akaszynski mentioned this pull request Sep 8, 2020
adeak added a commit to adeak/pyvista that referenced this pull request Nov 9, 2020
* upstream/master: (37 commits)
  🔧 Fix unused variables (pyvista#847)
  Add better Unstructured Grid Documentation (pyvista#845)
  Fix typo in plotting.py (pyvista#846)
  Feat: Implement compute_derivative (pyvista#837)
  New probe filter and massively improve interpolate filter (pyvista#842)
  Clarify clip filter docstring (pyvista#840)
  Update create-structured-surface.py (pyvista#844)
  Update topo-map.py (pyvista#841)
  Add release suffix to version string (pyvista#817)
  Add pathlib Support (pyvista#836)
  Add tolerance argument to sample_over_line (pyvista#828)
  vector slice from pyvista/pyvista-support#134 (pyvista#808)
  Fix is_all_triangles (pyvista#832)
  Misc. documentation fixes (pyvista#829)
  Follow up pyvista#793: fix get_data_range (pyvista#818)
  Fix GPU info in scooby report (pyvista#825)
  Patch for auto_close warning (pyvista#798)
  Add texture demo with scalar data (pyvista#821)
  MAINT: Log init start/stop (pyvista#819)
  Add PolyData strip filter (pyvista#807)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Anything related to the documentation/website
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants