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

Refactor branch #6

Merged
merged 6 commits into from
Feb 19, 2024
Merged

Refactor branch #6

merged 6 commits into from
Feb 19, 2024

Conversation

RSWilson1
Copy link
Collaborator

@RSWilson1 RSWilson1 commented Feb 16, 2024

Added changes to cover more with tests and change functionality of some code:

  • HGNC_id if multiple, returns error rather than continuing. There shouldn't be multiple HGNC ids so this shouldn't break anything unless gff is broken/changes.
  • Added test to check for empty annotation_df and move code to fit into functions better.
  • Added tests for merge_overlapping function and updated it to merge after combining annotation_df and coordinates_df.

This change is Reviewable

- Fixed ValueError return for mutliple HGNC_ids
- Updated merge_overlapping function to return correct df according to docstring.
- Moved order in write_bed so collapsing is done after combining coordinates_df and annotation_df.
-Write_bed also returns the correct empty df now.
-Removed some lines from write_bed into merge_overlapping to make consistent.
- Added additional example cmd to script docstring
Tests added:
- Test for empty annotation_df and correct results.
- Test am error is raised for multiple hgnc ids.
- Test correct merged_overlapping coordinates returned.
…ecting only NM_ transcripts, this might be removed on consultation.

Added section explaining how to use this with VEP.
Added example of gff3 tsv.
@pep8speaks
Copy link

pep8speaks commented Feb 16, 2024

Hello @RSWilson1! Thanks for updating this PR. We checked the lines you've touched for PEP 8 issues, and found:

Line 312:80: E501 line too long (94 > 79 characters)

Line 529:80: E501 line too long (93 > 79 characters)
Line 543:80: E501 line too long (95 > 79 characters)
Line 557:80: E501 line too long (85 > 79 characters)
Line 667:80: E501 line too long (87 > 79 characters)
Line 668:80: E501 line too long (90 > 79 characters)
Line 669:80: E501 line too long (84 > 79 characters)
Line 681:80: E501 line too long (89 > 79 characters)

Comment last updated at 2024-02-19 09:45:44 UTC

@RSWilson1 RSWilson1 self-assigned this Feb 16, 2024
Copy link
Contributor

@jethror1 jethror1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed 2 of 4 files at r1, 2 of 2 files at r2, all commit messages.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved (waiting on @RSWilson1)

Copy link
Contributor

@jethror1 jethror1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewable status: :shipit: complete! all files reviewed, all discussions resolved (waiting on @RSWilson1)

@jethror1 jethror1 merged commit bf8a9a8 into main Feb 19, 2024
2 checks passed
@jethror1 jethror1 deleted the refactor_branch branch February 19, 2024 10:32
@RSWilson1 RSWilson1 restored the refactor_branch branch February 23, 2024 09:17
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

Successfully merging this pull request may close these issues.

3 participants