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

Sort/index according to closeness to a point #3

Open
Ruibin-Liu opened this issue Mar 18, 2022 · 0 comments
Open

Sort/index according to closeness to a point #3

Ruibin-Liu opened this issue Mar 18, 2022 · 0 comments
Labels
enhancement New feature or request

Comments

@Ruibin-Liu
Copy link
Owner

Ruibin-Liu commented Mar 18, 2022

Currently, points or coordinates are sorted by the first dimension first and then the next dimensions. This makes the indexing/pseudo-grouping start from a corner and end at the furthest opposite corner. There is nothing wrong to organize the data in this way but it's interesting whether we can start from an arbitrary point and pseudo group points around it according to their distances to it.

Thoughts:

  1. Transform each data points around the chosen point by absolute difference in each direction;
  2. Sort the transformed data;
  3. Transform the data back to their original values but keep the indexing.
@Ruibin-Liu Ruibin-Liu added the enhancement New feature or request label Mar 22, 2022
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

No branches or pull requests

1 participant