column_dictionary {MungeSumstats}R Documentation

Map column names to positions.

Description

Useful in situations where you need to specify columns by index instead of name (e.g. awk queries).

Usage

column_dictionary(file_path)

Arguments

file_path

Path to full summary stats file (or any really file you want to make a column dictionary for).

Value

Named list of column positions.

Source

Borrowed function from echotabix.

eduAttainOkbayPth <- system.file("extdata", "eduAttainOkbay.txt", package = "MungeSumstats" ) tmp <- tempfile(fileext = ".tsv") file.copy(eduAttainOkbayPth, tmp) cdict <- MungeSumstats:::column_dictionary(file_path = tmp)


[Package MungeSumstats version 1.2.2 Index]