twas_methods

R codes and data here are used for simulations, to compare different TWAS methods: GLM 2SRI, GLM 2SPS, LM 2SRI, LM 2SPS.

Currently there are 3 files:

  1. "sample_gene_expression_and_snp.Rdata": simulation data;
  2. "one_sample_simulation.R": codes used to perform one sample simulations as described in the paper;
  3. "two_sample_simulation.R": codes used to perform two sample simulations as described in the paper.

Descriptions of functions are provided as comments in the codes, please ask Haoran if you have any questions running the codes.