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

Handle A1/REF/ALT from plink2 glm #44

Open
ofrei opened this issue Dec 8, 2020 · 1 comment
Open

Handle A1/REF/ALT from plink2 glm #44

ofrei opened this issue Dec 8, 2020 · 1 comment

Comments

@ofrei
Copy link
Contributor

ofrei commented Dec 8, 2020

To handle plink2 glm results we may need something like this:

df['A2'] = [(ref if (alt==a1) else alt) for ref, alt, a1 in zip(df['REF'].values, df['ALT'].values, df['A1'].values)]

Sample from plink2 glm output:

REF ALT	A1
A	G	G	
C	T	C	
T	G	G	
C	A	C	
C	T	T	
T	C	T	
G	A	G	
G	A	A	
G	A	G	
@denvdm
Copy link

denvdm commented Sep 18, 2023

Yeah, to pile on to this, would be nice to have sumstats.py recognize plink2 standard column names. Currently, besides the REF and ALT allele columns, #CHROM, and ID are not interpreted/deleted. Of course I know how to manually override this, but given plink2 is now used more and more, good to make this automatic?

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