Mercurial > repos > iuc > ggplot2_histogram
comparison utils.r @ 13:6b9816a913de draft default tip
planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/ggplot2 commit 57b86418a4f032a5664b8dc1c9585a11be629158
author | iuc |
---|---|
date | Thu, 15 May 2025 13:02:22 +0000 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
12:6fc8bab811da | 13:6b9816a913de |
---|---|
1 # Function for the data input | |
2 load_data <- function(file_name, file_extension) { | |
3 if (file_extension == "csv") { | |
4 data_input <- read.csv(file_name, check.names = "false") | |
5 } else if (file_extension %in% c("tsv", "txt", "tabular")) { | |
6 data_input <- read.delim(file_name, sep = "\t", check.names = "false") | |
7 } else if (file_extension == "parquet") { | |
8 data_input <- arrow::read_parquet(file_name) | |
9 } else { | |
10 stop("Unsupported file format.") | |
11 } | |
12 return(data_input) | |
13 } |