This function retrieves variant information from Ensembl based on the specified genomic position. It takes the chromosome number, start position, and end position as input parameters and searches for variants within this window, using the specified genomic build. If only the start position is provided, the function automatically sets the end position equal to the start position. This is particularly relevant for SNP variants, where the start and end positions are the same. The function returns all variants found within the defined window.
findRSID(
chromosome,
start_position,
end_position = NULL,
build = "38",
file_path = NULL
)A data.table containing variant information including:
id: variant id in rsID format
alleles: variant alleles
seq_region_name: chromosome number
start: starting base pair
end: ending base pair
Numeric, specifying the chromosome number.
Numeric, specifying the starting base pair position.
Numeric, specifying the ending base pair position.
Numeric, specifying the genomic build, default value is 38.
character, path to a file for saving results as Excell spreadsheet.