Skip to contents

Download bam.

Usage

DownloadBam(
  gsm.df,
  bam.type = c("10x", "other"),
  prefetch.path = NULL,
  samdump.path = NULL,
  out.folder = NULL,
  prefetch.paras = "-X 100G",
  samdump.paras = ""
)

Arguments

gsm.df

Dataframe contains GSM and Run numbers, obtained from ExtractRun.

bam.type

The source of bam files to download, choose from 10x (e.g. CellRanger) or other. Default: 10x.

prefetch.path

Path to prefetch. Default: NULL (conduct automatic detection).

samdump.path

Path to sam-dump, used when bam.type is other. Default: NULL (conduct automatic detection).

out.folder

Output folder. Default: NULL (current working directory).

prefetch.paras

Parameters for prefetch. This should not contain --type or -T values. Default: "-X 100G".

samdump.paras

Parameters for sam-dump. Default: "".

Value

Dataframe contains failed runs or NULL.

Examples

# GSE138266.runs = ExtractRun(acce = "GSE138266", platform = "GPL18573")
# GSE138266.down = DownloadBam(gsm.df = GSE138266.runs, bam.type = "10x", prefetch.path = "/path/to/prefetch",
#                              out.folder = "/path/to/output")