Learn R Programming

qgg (version 1.1.6)

mapSets: Map Sets to rsids

Description

This function maps sets to rsids. If a `Glist` is provided, `rsids` are extracted from the `Glist`. It returns a list of matched RSIDs for each set.

Usage

mapSets(sets = NULL, rsids = NULL, Glist = NULL, index = TRUE)

Value

A list where each element represents a set and contains matched RSIDs or their indices.

Arguments

sets

A list of character vectors where each vector represents a set of items. If the names of the sets are not provided, they are named as "Set1", "Set2", etc.

rsids

A character vector of RSIDs. If `Glist` is provided, this parameter is ignored.

Glist

A list containing an element `rsids` which is a character vector of RSIDs.

index

A logical. If `TRUE` (default), it returns indices of RSIDs; otherwise, it returns the RSID names.