-
Notifications
You must be signed in to change notification settings - Fork 5
Description
R.3.5.2.>features.rmsk <- getFeatures(tables=c("rmsk"),genome="mm10", cachedir=cachedir,sync=TRUE)
|==================================================|
Error in setnames(x, c("chrom", "chromStart", "chromEnd"), c("chr", "start", :
Items of 'old' not found in column names: chrom,chromStart,chromEnd
R.3.5.2.>
R.3.5.2.>traceback()
6: stop("Items of 'old' not found in column names: ", paste(old[is.na(i)],
collapse = ","))
5: setnames(x, c("chrom", "chromStart", "chromEnd"), c("chr", "start",
"end"))
4: FUN(X[[i]], ...)
3: lapply(tab.dt, togr)
2: lapply(tab.dt, togr)
1: getFeatures(tables = c("rmsk"), genome = genome, cachedir = cachedir,
sync = TRUE)
Suggested partial fix:
if ("chrom" in colnames(x)){
setnames(x, c("chrom"), c("chr"))
} else {
stopifnot("chr" in colnames(x))
}
setnames(x, c("chromStart", "chromEnd"), c("start", "end"))