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

Variant Search sort on position #272

Open
bbimber opened this issue Apr 16, 2024 · 0 comments
Open

Variant Search sort on position #272

bbimber opened this issue Apr 16, 2024 · 0 comments
Assignees

Comments

@bbimber
Copy link
Contributor

bbimber commented Apr 16, 2024

Within the genome, we have chromosome plus position, which are independent fields. From a human perspective, sorting on "position" most logically means the combination of chromosome + position, where chromosome establishes a sort order. To facilitate this, we already compute a "genomePosition" field, which creates a single numeric series to order positions in the "human correct" order.

When the user tries to sort the variant search results on position, I think we should silently use genomicPosition as the actual sort field. Otherwise sorting on position gives weird results like:

Chrom1 1
Chrom2 1
Chrom3 1
....
Chrom1 2
Chrom2 2
Chrom3 2

We could either handle this client-side, or look for this string server-side. I cant think of a reason either is better or worse. I wonder if the chromosome/contig field should have the same behavior.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants