Thanks to visit codestin.com
Credit goes to github.com

Skip to content

[Doc] Improve axisartist documentation#27351

Open
oscargus wants to merge 1 commit into
matplotlib:mainfrom
oscargus:axislinedocs
Open

[Doc] Improve axisartist documentation#27351
oscargus wants to merge 1 commit into
matplotlib:mainfrom
oscargus:axislinedocs

Conversation

@oscargus
Copy link
Copy Markdown
Member

PR summary

Some improvements to the axisartist documentation. Can be further improved, but at least providing a bit more info.

PR checklist

@oscargus oscargus added topic: mpl_toolkit Documentation: API files in lib/ and doc/api labels Nov 20, 2023
axes : `mpl_toolkits.axisartist.axislines.Axes`
nth_coord : {0, 1}, optional
Along which coordinate the value varies in 2D. 0: x-axis, 1: y-axis.
passingthrough_point :
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Rename to "value" for consistency with the parent class?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

I was considering the other way around, since passingthrough_point gives some information about what it is used for. But with a good description (which it currently lacks...), value is probably easier to remember/spell etc.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I think it would be much simpler to document nth_coord and value (or passingthrough_point, which is not even really well named as it's a scalar value, not a 2d point) together as something like "nth_coord = 0; value = v means to draw an axis at x=v; nth_coord = 1; value = v means to draw an axis at y=v". (By the way this suggests that your wording for nth_coord's doc is also "wrong"?)

Parameters
----------
loc : ["left", "right", "top", "bottom"]
axis_direction : ["left", "right", "top", "bottom"], optional
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

just ..., default: *loc*

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants