calculate effective sample size per SNP

90 views
Skip to first unread message

lydia li

unread,
Nov 27, 2024, 2:50:26 PM11/27/24
to Genomic SEM Users
Hi everyone,
I used the formula provided in the GSEM wiki  (https://github.com/GenomicSEM/GenomicSEM/wiki/2.1-Calculating-Sum-of-Effective-Sample-Size-and-Preparing-GWAS-Summary-Statistics )to calculate the effective sample size per SNP for a few binary traits. Note that I have imbalances in case/control proportions per trait and non-independence among participants. 

 In particular, I used this line of code as the template:  <ANX$Neff<-4/((2*ANX$MAF*(1-ANX$MAF))*ANX$StdErr^2)>,  and did not do the capping as i have already filtered markers based on quality and MAF, but the results were quite off (i.e., the resulted N effect is ~100 times larger than the total number of participants). 

if I add the capping indicated in the GSEM, the yielded effective sample size per snp is too small for reliable sub-sequential analysis. I wonder if there are some other ways to calculate effective sample size per SNP so that I can cross check my results.  
Thank you very much! 
Lydia

lydia li

unread,
Nov 27, 2024, 3:09:22 PM11/27/24
to Genomic SEM Users
should I use this formula instead? 
Screenshot 2024-11-27 at 3.08.58 PM.png

Elliot Tucker-Drob

unread,
Nov 27, 2024, 4:26:09 PM11/27/24
to lydia li, Genomic SEM Users
Given that I don't know the specifics of your data, I think it would be best for you to consult the original paper, the PDF of which is linked to here:

Grotzinger, A. D., de la Fuente, J., Privé, F., Nivard, M. G., & Tucker-Drob, E. M. (2023). Pervasive downward bias in estimates of liability scale heritability in GWAS meta-analysis: A simple solution. Biological Psychiatry, 93. PDF

best wishes,
Elliot Tucker-Drob

--
You received this message because you are subscribed to the Google Groups "Genomic SEM Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to genomic-sem-us...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/genomic-sem-users/88af356e-4547-4ef2-bbe8-26d1158952adn%40googlegroups.com.

lydia li

unread,
Nov 28, 2024, 1:12:19 PM11/28/24
to Genomic SEM Users
Thank you Dr. Tucker-Drob! My summary stats of binary traits come from one cohort/ one single study with n_control and n_cases specified. Does it mean that I actually do not need correction for biases (calculating Neff and capping)? 

Elliot Tucker-Drob

unread,
Nov 29, 2024, 2:00:51 PM11/29/24
to lydia li, Genomic SEM Users
In that case you can use the standard liability threshold model and simply enter the relevant prevalences and observed sample sizes. 

Reply all
Reply to author
Forward
0 new messages