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

ENH: add preserve_index keyword to gdf_to_nx to allow preservation of index and order #641

Merged
merged 4 commits into from
Jul 11, 2024

Conversation

martinfleis
Copy link
Member

Conversion to nx and back currently messes up the order of the rows and does not preserve index at all. This allows for a 1:1 roundtrip needed to keep the Graph objects and anything linked to index aligned.

Copy link

codecov bot commented Jul 11, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 98.2%. Comparing base (4037c70) to head (e5f196a).
Report is 88 commits behind head on main.

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff           @@
##            main    #641     +/-   ##
=======================================
+ Coverage   97.4%   98.2%   +0.8%     
=======================================
  Files         26      38     +12     
  Lines       4328    6253   +1925     
=======================================
+ Hits        4214    6138   +1924     
- Misses       114     115      +1     
Files with missing lines Coverage Δ
momepy/tests/test_utils.py 99.4% <100.0%> (+0.2%) ⬆️
momepy/utils.py 99.1% <100.0%> (+0.2%) ⬆️

@jGaboardi jGaboardi added the enhancement New feature or request label Jul 11, 2024
@jGaboardi jGaboardi merged commit efb11dd into pysal:main Jul 11, 2024
15 checks passed
@martinfleis martinfleis deleted the gdf=nx=order branch July 11, 2024 12:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants