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

plyranges: facilitate adding metadata columns via join_mcols_* #10

Open
mikelove opened this issue Sep 23, 2023 · 7 comments
Open

plyranges: facilitate adding metadata columns via join_mcols_* #10

mikelove opened this issue Sep 23, 2023 · 7 comments
Labels
enhancement New feature or request

Comments

@mikelove
Copy link
Member

mikelove commented Sep 23, 2023

Currently, for GRanges x, to add metadata to mcols(x) one must do:

mcols(x) <- mcols(x) |>
  as_tibble() |>
  left_join(extra_info)

This could be turned into a plyranges convenience function, join_mcols_*, with * being left or inner.

@mikelove mikelove converted this from a draft issue Sep 23, 2023
@mikelove mikelove added enhancement New feature or request good first issue Good for newcomers labels Sep 23, 2023
@nahid18
Copy link
Member

nahid18 commented Oct 2, 2023

@mikelove this looks simple enough (I could be very wrong). I will explore the source code and if I can do it, I will assign myself

@mikelove
Copy link
Member Author

mikelove commented Oct 2, 2023

I think it should be simple. You can make a PR by forking plyranges and working on a new feature branch, and then we can ping Stuart to see if he likes it.

@isongjosiah
Copy link

Hi, @nahid18 still working on this?

@mikelove
Copy link
Member Author

There is a related work from tidySE to allow joins on DataFrames. See the project list, I think it’s @lambdamoses

@isongjosiah
Copy link

Thanks for the pointer, @mikelove - the issue seems to be completed. Did you mean the mcols support for GRange?

@mikelove
Copy link
Member Author

Sorry — from phone — but I thought it would allow for join onto DataFrame such as rowData.

@stemangiola
Copy link

I believe we developed left join from DataFrama in tidy transcriptomics. Should be one of the challenges.

As a note: could left_join be the method extended here rather than creating a new method?

@mikelove mikelove removed the good first issue Good for newcomers label Nov 10, 2024
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
Status: Todo
Development

No branches or pull requests

4 participants