Entering edit mode
                    4.5 years ago
        nlt_220593
        
    
        ▴
    
    20
    I am using the below command in order to obtain LD matrix of a list of SNP:
plink --bfile 1000G_reference_panel_filename --r --ld-snp-list snp_list.txt
And It works, but I need to export a matrix format, instead of the default format.
I tried to perform the next:
plink --bfile 1000G_reference_panel_filename --r bin --ld-snp-list snp_list.txt 
But an error appears:
Error: --ld-snp/--ld-snps/--ld-snp-list cannot be used with the --r/--r2 matrix
output modifiers.
How could I obtain the matrix format?
If you want a square matrix with the SNPs in
snp_list.txt, you can replace--ld-snp-listwith--extract.However, if you want a rectangular matrix with just the
snp_list.txtvariants on one dimension, and all SNPs on the other dimension, you can't generate that directly with plink. You'd probably want to postprocess the tabular--routput instead.