<jupyter_start><jupyter_text>random snippets load multiple csv files and rowbind into R matrix<jupyter_code>print("loading data from CSV files")

BASE <- "/home/jovyan/data/mk/timeseries/"
dataPath <- function(x){
  return(paste(c(BASE, x, ".csv"), collapse = ""))
}


d <- read.csv(dataPath(1))

for ( i in 2:7){
  path <- dataPath(i)
  print(path)
  d <- rbind(d, read.csv(path))
  gc()
}<jupyter_output>[1] "loading data from CSV files"
[1] "/home/jovyan/data/mk/timeseries/2.csv"
[1] "/home/jovyan/data/mk/timeseries/3.csv"
[1] "/home/jovyan/data/mk/timeseries/4.csv"
[1] "/home/jovyan/data/mk/timeseries/5.csv"
[1] "/home/jovyan/data/mk/timeseries/6.csv"
[1] "/home/jovyan/data/mk/timeseries/7.csv"
{'fraction_non_alphanumeric': 0.20056899004267426, 'fraction_numerical': 0.02275960170697013, 'mean_word_length': 4.293233082706767, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 4, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '1', 'dir': 'jupyter-structured-clean-dedup', 'id': '74637', 'license': 'MIT', 'n_tokens_mistral': 314, 'n_tokens_neox': 298, 'n_words': 54, 'path': 'SDM/R-jupyter/000-random.ipynb', 'repo_name': 'markuskont/CDMCS', 'size': '703'}