A set of useful functions for genomic data analysis.
devtools::install_github("XikunHan/geneticToolBox")
library(geneticToolBox)
# check many large files, eg. GWAS summary statistics.
df <- file_info(path = "~/data/", pattern = "GWAS")
summary(df)
df[which.min(size_MB), ]
# check many log files
df <- read_last_line(path = "~/log/", pattern = ".")
dd <- df[!str_detect(content, "Warning"), ]
# eg. data type of IDs, duplicates
merge_check(df_1, df_2, by.x = "ID1", by.y = "ID2")
df_m <- mergeDataSets(list(df_1, df_2, df_3), by = "id", all = TRUE)
df_res <- meta_inverse_variance_df(df_res, beta1 = "estimate_1", se1 = "std.error_1",
beta2 = "estimate_2", se2 = "std.error_2")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.