diff options
| author | Alexander_Kabui | 2024-10-25 16:51:55 +0300 |
|---|---|---|
| committer | Alexander_Kabui | 2024-10-25 21:47:48 +0300 |
| commit | fe1e3b600511ceedbd6778618d2c0d7e9ea2ffb6 (patch) | |
| tree | 9c1feed821c99a7c6e0d6ae01b1197ae6723d338 | |
| parent | faeee466b37a1df2792b9596c669496fce38d3df (diff) | |
| download | genenetwork3-fe1e3b600511ceedbd6778618d2c0d7e9ea2ffb6.tar.gz | |
feat: add function to fetch load peaks for 1 QTL.
| -rw-r--r-- | scripts/rqtl2_wrapper.R | 21 |
1 files changed, 20 insertions, 1 deletions
diff --git a/scripts/rqtl2_wrapper.R b/scripts/rqtl2_wrapper.R index babf19e..cbf2b93 100644 --- a/scripts/rqtl2_wrapper.R +++ b/scripts/rqtl2_wrapper.R @@ -315,7 +315,7 @@ perform_permutation_test <- function(cross, } else if (method == "LOCO") { kinship = calc_kinship(genome_prob, "loco") - operm3 <- scan1perm( + perm <- scan1perm( genome_prob, cross$pheno, kinship = kinship , @@ -331,3 +331,22 @@ perform_permutation_test <- function(cross, perm <- perform_permutation_test(dataset, Pr, n_perm = 2, method = "LMM") # get the permutation summary with a significance threshold summary(perm, alpha = c(0.2, 0.05)) + +# find function to perform the LOD peaks + +find_lod_peaks <-function(scan_results, cross, threshold=4, drop=1.5){ +# can this take pmap??? which map should we use??? +# TODO add more ags +print("Finding the lod peaks with thresholds n and drop n\n") +return (find_peaks(scan_results, cross$gmap, threshold= threshold, drop=drop)) +} + +# add the number of cores +lod_peaks <- find_lod_peaks(results, dataset) +print(load_peaks) + +# how can we perform qtl effect computations ??? with input from user + +# what data should we return to the user + +# improve on this script \ No newline at end of file |
