pysal / momepy

Urban Morphology Measuring Toolkit
https://docs.momepy.org
BSD 3-Clause "New" or "Revised" License
495 stars 59 forks source link

BUG: fix describe_ function when count is not present #608

Closed u3ks closed 5 months ago

u3ks commented 5 months ago

a fix for a small issue with the mm.describe_* functions, where they expect a count to always be calculated

codecov[bot] commented 5 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 98.0%. Comparing base (4037c70) to head (2197a66). Report is 85 commits behind head on main.

Additional details and impacted files [![Impacted file tree graph](https://app.codecov.io/gh/pysal/momepy/pull/608/graphs/tree.svg?width=650&height=150&src=pr&token=VNn0WR5JWT&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pysal)](https://app.codecov.io/gh/pysal/momepy/pull/608?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pysal) ```diff @@ Coverage Diff @@ ## main #608 +/- ## ======================================= + Coverage 97.4% 98.0% +0.6% ======================================= Files 26 37 +11 Lines 4328 6078 +1750 ======================================= + Hits 4214 5956 +1742 - Misses 114 122 +8 ``` | [Files with missing lines](https://app.codecov.io/gh/pysal/momepy/pull/608?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pysal) | Coverage Δ | | |---|---|---| | [momepy/functional/\_diversity.py](https://app.codecov.io/gh/pysal/momepy/pull/608?src=pr&el=tree&filepath=momepy%2Ffunctional%2F_diversity.py&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pysal#diff-bW9tZXB5L2Z1bmN0aW9uYWwvX2RpdmVyc2l0eS5weQ==) | `96.5% <100.0%> (ø)` | | | [momepy/functional/tests/test\_diversity.py](https://app.codecov.io/gh/pysal/momepy/pull/608?src=pr&el=tree&filepath=momepy%2Ffunctional%2Ftests%2Ftest_diversity.py&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pysal#diff-bW9tZXB5L2Z1bmN0aW9uYWwvdGVzdHMvdGVzdF9kaXZlcnNpdHkucHk=) | `100.0% <100.0%> (ø)` | |
martinfleis commented 5 months ago

Is this something that also needs to be included in Graph.describe?

u3ks commented 5 months ago

No, Graph.describe doesnt modify the output of pandas.agg, here we do to make it compatible with the old functionality