5 steps of p -value assignment, denoted by steps 9–13. Each site first calculates the components of the p -value statistics using local genotype and phenotype data. These are, T=G1'(Y1-μ0,1), G1'W1G1, G1'W1X1 * (X'WX)^-1, and G'WX. Next, each matrix is pooled among sites (Step 10) and the scale parameter is calculated, i.e., S=tr(G'WG)-<G'WX * (X'WX)^-1,G'WX>r2r, where tr(A) denotes the trace of matrix A. Next, each site generates a mask vector, denoted by N1, and elementwise multiplies with both T and S vector with the same mask vector. The masked statistics are pooled among sites to calculate the final collectively masked statistics, which are collectively decrypted and used for assigning final p -values.