hitman2_replication: High-throughput approach for testing directional replication...

View source: R/hitman2_replication.R

hitman2_replicationR Documentation

High-throughput approach for testing directional replication that uses filtering to improve adjusted p-values

Description

High-throughput approach for testing replication of two base studies, where each study applies a two-sided test whose signed statistic and p-value are supplied via tab, and its desired to find rows where there is replication in a common direction. Hitman2 improves on the adjusted p-values using filtering.

Usage

hitman2_replication(
  tab,
  cols = 1:4,
  reorder.rows = FALSE,
  p.adj.rate = c("FDR", "FWER"),
  prefix = NA
)

Arguments

tab

Matrix-like object with statistical and p-value columns. Only the signs of the statistics columns are used. tab should have non-duplicated row names and should not have missing values.

cols

Vector of column indices or names in the order of c(stat1, p1, stat2, p2).

reorder.rows

Logical, should rows be reordered by p-value?

p.adj.rate

Either "FDR" for false discovery rate or "FWER" for family-wise error rate, the rate controlled by the Bonferroni procedure.

prefix

Character string of length one with prefix of returned columns, e.g. if prefix="repl", returned columns might be c("repl.chisq", "repl.p", "repl.FDR"). Prefix is not added if it is NA.

Details

Larger chi-square values are more significant.

Value

Data frame whose rows correspond to the rows of tab with the same row names and whose columns are

chisq

Chi-square for replication on 1 degreee of freedom.

p

P-value for replication

FDR or FWER

FDR or FWER for replication


jdreyf/Hitman documentation built on April 12, 2025, 1:35 p.m.