.\" Manpage for QTLtools fdensity. .\" Contact halitongen@gmail.com to correct errors or typos. .TH QTLtools-fdensity 1 "06 May 2020" "QTLtools-v1.3" "Bioinformatics tools" .SH NAME QTLtools fdensity \- Functional density around molecular QTLs .SH SYNOPSIS .B QTLtools fdensity \-\-qtl .IR significant_genes.bed .B \-\-bed .IR TFs.encode.bed.gz .B \-\-out .IR output.txt .I [OPTIONS] .SH DESCRIPTION This mode measures the density of functional annotations around the genomic positions of molecular QTLs. The method is detailed in . In brief, we first enumerate all annotations within a given window around the molecular QTLs (by default 1 Mb). Then, we split this window into small bins (default 1 kb) and count the number of functional annotations overlapping each bin. This produces an annotation count per bin that can be then plotted to see if there is any peak or depletion around the molQTLs. .SH OPTIONS .TP .B \-\-qtl \fIin.bed\fB List of QTLs of interest in BED format. REQUIRED. .TP .B \-\-bed \fIfunctional_annotation.bed.gz\fR Functional annotations in BED format. REQUIRED. .TP .B \-\-out \fIoutput.txt\fR Output file. REQUIRED. .TP .B \-\-window \fIinteger\fR Window size around the molecular QTL position. DEFAULT=1000000 .TP .B \-\-bin \fIinteger\fR Bin size in base pairs. DEFAULT=1000 .SH INPUT FILES .TP 1 .B \-\-qtl file List of QTLs of interest. An example: .sp 1 1 15210 15211 1_15211 ENSG00000227232.4 - .sp 0 1 735984 735985 1_735985 ENSG00000177757.1 + .sp 0 1 735984 735985 1_735985 ENSG00000240453.1 - .sp 0 1 739527 739528 1_739528 ENSG00000237491.4 + .sp 1 The column definitions are: .TS n lx . 1 T{ The variant chromosome T} 2 T{ The variant's start position (\fB0-based\fR) T} 3 T{ The variant's end position (\fB1-based\fR) T} 4 T{ The variant ID T} 5 T{ The phenotype ID (\fBnot used\fR) T} 6 T{ The phenotype's strand. T} .TE .ta T 5 .TP 1 .B \-\-bed file List of annotations in BED format. An example: .sp 1 1 254874 265487 .sp 0 1 730984 735985 .sp 0 1 734984 736585 .sp 0 1 739527 748528 .sp 1 The column definitions are: .TS n lx . 1 T{ Chromosome T} 2 T{ Start position (\fB0-based\fR) T} 3 T{ End position (\fB1-based\fR) T} .TE .ta T 5 .SH OUTPUT FILE .TP 1 .B \fB\-\-out\fR file Space separated results output file detailing the enrichment with the following columns: .TS n lx . 1 T{ The start position of the bin T} 2 T{ The end position of the bin T} 3 T{ The number of associations in this bin T} .TE .SH EXAMPLE .IP 1 2 You need to prepare a BED file containing the positions of the QTLs of interest. To do so, extract all significant hits at a given FDR threshold (e.g. 5%), and then transform the significant QTL list into a BED file: .IP "" 2 Rscript ./script/qtltools_runFDR_cis.R results.genes.full.txt.gz 0.05 results.genes .sp 0 cat results.genes.significant.txt | awk '{ print $9, $10-1, $11, $8, $1, $5 }' | tr ' ' '\\t' | sort \-k1,1V \-k2,2g > results.genes.significant.bed .IP 2 2 Measure the density using the following command: .IP "" 2 QTLtools fdensity \-\-qtl results.genes.significant.bed \-\-bed TFs.encode.bed.gz \-\-out density.TF.around.QTL.txt .SH SEE ALSO .IR QTLtools (1) .\".IR QTLtools-bamstat (1), .\".IR QTLtools-mbv (1), .\".IR QTLtools-pca (1), .\".IR QTLtools-correct (1), .\".IR QTLtools-cis (1), .\".IR QTLtools-trans (1), .\".IR QTLtools-fenrich (1), .\".IR QTLtools-fdensity (1), .\".IR QTLtools-rtc (1), .\".IR QTLtools-rtc-union (1), .\".IR QTLtools-extract (1), .\".IR QTLtools-quan (1), .\".IR QTLtools-rep (1), .\".IR QTLtools-gwas (1), .PP QTLtools website: .SH BUGS Please submit bugs to .SH CITATION Delaneau, O., Ongen, H., Brown, A. et al. A complete tool set for molecular QTL discovery and analysis. \fINat Commun\fR \fB8\fR, 15452 (2017). .SH AUTHORS Olivier Delaneau (olivier.delaneau@gmail.com), Halit Ongen (halitongen@gmail.com)