  We present MRPC, an R package that learns causal graphs with improved
accuracy over existing packages, such as pcalg and bnlearn. Our algorithm
builds on the powerful PC algorithm, the canonical algorithm in computer
science for learning directed acyclic graphs. The improvement in accuracy
results from online control of the false discovery rate (FDR) that reduces
false positive edges, a more accurate approach to identifying v-structures
(i.e., $T_1 \rightarrow T_2 \leftarrow T_3$), and robust estimation of the
correlation matrix among nodes. For genomic data that contain genotypes and
gene expression for each sample, MRPC incorporates the principle of Mendelian
randomization to orient the edges. Our package can be applied to continuous and
discrete data.
