# Load packages
library(imageFeatureTCGA)
library(curatedTCGAData)
library(dplyr)
# Load assays for Kidney Cancer
kidney_mae_all <- curatedTCGAData("KIRC", assays = "*", version = "2.1.1", dry.run = FALSE)
kidney_assays_subset <- c(
"KIRC_RNASeq2GeneNorm-20160128",
"KIRC_RPPAArray-20160128",
"KIRC_mRNAArray-20160128"
)
kidney_mae <- kidney_mae_all[,, which(names(kidney_mae_all) %in% kidney_assays_subset)]
# Get the full catalog
catalog_full <- getCatalog("provgigapath") |>
dplyr::filter(level == "slide_level", Project.ID == "TCGA-KIRC")
# nrow(catalog_full) is around 500
# use linkTCGA
# This fails
kidney_mae_emb <- linkTCGA(kidney_mae, catalog_full, redownload = FALSE, parallel = FALSE)
# Error message:
# Error in h(simpleError(msg, call)) :
# error in evaluating the argument 'con' in selecting a method for function 'import':
# invalid class “TENxFile” object: Path or URL to the file must be valid
# Current Workaround being used
catalog_slice <- catalog_full |> dplyr::slice(1:100)
kidney_mae_emb_works <- linkTCGA(kidney_mae, catalog_slice, redownload = FALSE, parallel = FALSE)
# This succeeds
sessionInfo()
# R version 4.5.1 (2025-06-13), imageFeatureTCGA_1.1.0, curatedTCGAData_1.32.1
Reproducible example