# PLINK - Transposed BED file?

I'm currently working with the PLINK file system to store large amounts of genotype data.

The plain format consists of three files, two files for storing phenotype and marker information as well as one file (.PED) containing the genotype matrix.

There exists a binary version of the .PED file (.BED), which stores the data in a number of consecutive byte blocks, with each block encoding the genotype of all samples for a specific marker.

While there exists a transposed version of the .PED file (.TPED) which is also supported by PLINK, I couldn't find out whether there also exists a transposed version of the binary .BED file.

Does it exist at all? Are there other file formats to compactly store a genotype matrix for fast sample / marker extraction?

Yes, this exists, and can be efficiently generated by plink 2.0's --export ind-major-bed command. (The third byte is 0 instead of 1, and the specification is otherwise identical to that of regular plink .bed files with samples and variants swapped.)