-
Notifications
You must be signed in to change notification settings - Fork 31
Improved Documentation #63
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
Conversation
- Added some doc tests - Minor reformatting
- More documentations are added. - Also adjusted some formatting.
- Merged imports - By enabling `clippy::all` and `clippy::pedantic` lints, - Marked several methods as `must_use` - Found a redundant closue ( `Bins::len` is also more informative on the type than `|e| e.len()` )
`left inclusive` and `right exclusive` are not standard math terminology. It should be phrased as `left-closed` and `right-open`.
`Out of bound` -> `Out of bounds` `Out-of-bound` -> `Out-of-bounds`
- Rewrites and reformats docs. Hopefully it's more aligned to the style in std library. - Replaced `left-inclusive-right-exclusive` by `left-closed-right-open`, which is more common in maths.
- Added `missing_docs` lints from `rustc` - Added `clippy::all` and `clippy::pedantic` lints - Marked methods with `must_use` - Improved code style according to clippy
- Added more information in mod-level documentation, including - A section for strategies currently implemented - A section for requirement of data to infer optimal parameters - Reformatting
- Added `missing_docs`, `clippy::all`, and `cippy::pedantic` lints - They helped to find certain problems when casting values into other types, none of the warning is relavant and are suppresed and commented - It also warns that the private function `bin_width` doesn't consume the input, so their type signature can be changed to a reference. But actually this is because this function `clone`ed the inputs. This is not a good pattern as it hides the clones. It's better to leave this to the caller and make the clone explicit. So this commit removed the `clone` inside of this function, and documented that the inputs would be consumed.
@lebensterben I was going to take a look at this with a view of merging it. Just wondering if there was a specific reason it was in draft i.e. more planned changes etc?
So I've spent some time going over all these changes and I think they're all good and see no issues. So I'm going to merge this with the view of getting a new version of ndarray-stats out with them included 👍
@xd009642
Hi,
I spotted some features not implemented and started implementing them, but then I have to work on other stuff so it's not finished yet.
Ah fair enough, if you want to raise an issue or open another PR since I merged this one. I think a general issue with a checklist of missing or lacking parts of the docs would be good
histogram/grid.rs: Docs