Adjusted scripts so they will find files

This commit is contained in:
Nora Wickelmaier 2023-12-21 14:46:59 +01:00
parent 9c6466bca9
commit 9992a94712
10 changed files with 17 additions and 17 deletions

View File

@ -9,7 +9,7 @@
# (3.4) Artwork sequences # (3.4) Artwork sequences
# (3.5) Topics # (3.5) Topics
# #
# input: ../data/haum/event_logfiles_glossar_2023-10-29_10-26-42.csv # input: results/haum/event_logfiles_glossar_2023-10-29_10-26-42.csv
# output: # output:
# #
# last mod: 2023-11-15, NW # last mod: 2023-11-15, NW
@ -27,7 +27,7 @@ library(bupaverse)
#--------------- (1) Read data --------------- #--------------- (1) Read data ---------------
dat <- read.table("../data/haum/event_logfiles_glossar_2023-11-03_17-46-28.csv", dat <- read.table("results/haum/event_logfiles_glossar_2023-11-03_17-46-28.csv",
sep = ";", header = TRUE) sep = ";", header = TRUE)
dat$date <- as.POSIXct(dat$date) dat$date <- as.POSIXct(dat$date)
dat$date.start <- as.POSIXct(dat$date.start) dat$date.start <- as.POSIXct(dat$date.start)

View File

@ -12,7 +12,7 @@ from sklearn.cluster import KMeans
###### Load data and create event logs ###### ###### Load data and create event logs ######
dat = pd.read_csv("../data/haum/event_logfiles_glossar_2023-11-03_17-46-28.csv", sep = ";") dat = pd.read_csv("results/haum/event_logfiles_glossar_2023-11-03_17-46-28.csv", sep = ";")
dat = dat[dat.date < "2020-03-13"] dat = dat[dat.date < "2020-03-13"]
# --> only pre corona (before artworks were updated) # --> only pre corona (before artworks were updated)

View File

@ -9,7 +9,7 @@
# #
# input: results/eval_heuristics_artworks.csv # input: results/eval_heuristics_artworks.csv
# results/eval_all-miners_complete.csv # results/eval_all-miners_complete.csv
# ../data/haum/event_logfiles_glossar_2023-11-03_17-46-28.csv # results/haum/event_logfiles_glossar_2023-11-03_17-46-28.csv
# output: ../figures/clustering_heuristics.pdf # output: ../figures/clustering_heuristics.pdf
# ../figures/clustering_heuristics.png # ../figures/clustering_heuristics.png
# ../figures/processmaps/dfg_complete_R.pdf # ../figures/processmaps/dfg_complete_R.pdf
@ -143,7 +143,7 @@ for (art in as.numeric(rownames(eval_inductive))) {
#--------------- (4) Read event logs --------------- #--------------- (4) Read event logs ---------------
dat <- read.table("../data/haum/event_logfiles_glossar_2023-11-03_17-46-28.csv", dat <- read.table("results/haum/event_logfiles_glossar_2023-11-03_17-46-28.csv",
sep = ";", header = TRUE) sep = ";", header = TRUE)
dat$date <- as.POSIXct(dat$date) dat$date <- as.POSIXct(dat$date)
dat$date.start <- as.POSIXct(dat$date.start) dat$date.start <- as.POSIXct(dat$date.start)

View File

@ -13,7 +13,7 @@ datraw <- parse_logfiles(folders, path = "../data/8o8m/LogFiles/")
#artworks <- unique(na.omit(datraw$artwork)) #artworks <- unique(na.omit(datraw$artwork))
# export data # export data
write.table(datraw, paste0("../data/8o8m/raw_logfiles_", now, ".csv"), write.table(datraw, paste0("results/8o8m/raw_logfiles_", now, ".csv"),
sep = ";", row.names = FALSE) sep = ";", row.names = FALSE)
#datraw[is.na(datraw$artwork), ] #datraw[is.na(datraw$artwork), ]
@ -32,6 +32,6 @@ topics <- extract_topics(artworks, xmlfiles = paste0(artworks, "_en.xml"),
# extracted like this? (It works fine for the English versions...) # extracted like this? (It works fine for the English versions...)
# export data # export data
write.table(datlogs, paste0("../data/8o8m/event_logfiles_", now, ".csv"), write.table(datlogs, paste0("results/8o8m/event_logfiles_", now, ".csv"),
sep = ";", row.names = FALSE) sep = ";", row.names = FALSE)

View File

@ -30,12 +30,12 @@ now <- format(Sys.time(), "%Y-%m-%d_%H-%M-%S")
#datraw <- parse_logfiles(folders, path) #datraw <- parse_logfiles(folders, path)
datraw <- read.table("../data/haum/raw_logfiles_2023-10-25_16-20-45.csv", datraw <- read.table("results/haum/raw_logfiles_2023-10-25_16-20-45.csv",
sep = ";", header = TRUE) sep = ";", header = TRUE)
## Export data ## Export data
#write.table(datraw, paste0("../data/haum/raw_logfiles_small_", now, ".csv"), #write.table(datraw, paste0("results/haum/raw_logfiles_small_", now, ".csv"),
# sep = ";", row.names = FALSE) # sep = ";", row.names = FALSE)
#--------------- (2) Create event logs --------------- #--------------- (2) Create event logs ---------------
@ -107,7 +107,7 @@ dat2 <- merge(dat1, sfdat, by.x = "date", by.y = "date", all.x = TRUE)
## Export data ## Export data
write.table(dat2, paste0("../data/haum/event_logfiles_glossar_", now, ".csv"), write.table(dat2, paste0("results/haum/event_logfiles_glossar_", now, ".csv"),
sep = ";", row.names = FALSE) sep = ";", row.names = FALSE)
# TODO: Maybe add infos about artworks? # TODO: Maybe add infos about artworks?

View File

@ -5,7 +5,7 @@ devtools::load_all("../../../../software/mtt")
library(ggplot2) library(ggplot2)
# Read data # Read data
datlogs <- read.table("../data/8o8m/event_logfiles_2023-09-22_18-54-49.csv", datlogs <- read.table("results/8o8m/event_logfiles_2023-09-22_18-54-49.csv",
sep = ";", header = TRUE) sep = ";", header = TRUE)
datlogs$date <- as.Date(datlogs$date.start) datlogs$date <- as.Date(datlogs$date.start)
datlogs$date.start <- as.POSIXct(datlogs$date.start) datlogs$date.start <- as.POSIXct(datlogs$date.start)

View File

@ -7,7 +7,7 @@ library(lattice)
#plot(1:10, col = cc, pch = 16, cex = 2) #plot(1:10, col = cc, pch = 16, cex = 2)
# Read data # Read data
datlogs <- read.table("../data/haum/event_logfiles_metadata_2023-09-23_01-31-30.csv", datlogs <- read.table("results/haum/event_logfiles_metadata_2023-09-23_01-31-30.csv",
sep = ";", header = TRUE) sep = ";", header = TRUE)
datlogs$date <- as.Date(datlogs$date) datlogs$date <- as.Date(datlogs$date)
datlogs$date.start <- as.POSIXct(datlogs$date.start) datlogs$date.start <- as.POSIXct(datlogs$date.start)

View File

@ -2,7 +2,7 @@
# Read data # Read data
dat0 <- read.table("../data/haum/event_logfiles_2023-10-25_17-29-52.csv", dat0 <- read.table("results/haum/event_logfiles_2023-10-25_17-29-52.csv",
sep = ";", header = TRUE) sep = ";", header = TRUE)
dat0$date.start <- as.POSIXct(dat0$date.start) dat0$date.start <- as.POSIXct(dat0$date.start)
dat0$date.stop <- as.POSIXct(dat0$date.stop) dat0$date.stop <- as.POSIXct(dat0$date.stop)

View File

@ -2,9 +2,9 @@
# Read data # Read data
# dat <- read.table("../data/haum/event_logfiles_metadata_2023-09-23_01-31-30.csv", # dat <- read.table("results/haum/event_logfiles_metadata_2023-09-23_01-31-30.csv",
# sep = ";", header = TRUE) # sep = ";", header = TRUE)
dat <- read.table("../data/haum/event_logfiles_small_metadata_2023-10-15_10-08-43.csv", dat <- read.table("results/haum/event_logfiles_small_metadata_2023-10-15_10-08-43.csv",
sep = ";", header = TRUE) sep = ";", header = TRUE)
dat$date <- as.Date(dat$date) dat$date <- as.Date(dat$date)
dat$date.start <- as.POSIXct(dat$date.start) dat$date.start <- as.POSIXct(dat$date.start)

View File

@ -1,6 +1,6 @@
# setwd("C:/Users/nwickelmaier/Nextcloud/Documents/MDS/2023ss/60100_master_thesis/code") # setwd("C:/Users/nwickelmaier/Nextcloud/Documents/MDS/2023ss/60100_master_thesis/code")
dat <- as.data.frame(do.call(rbind, XML::xmlToList("../data/haum/trans.xml"))) dat <- as.data.frame(do.call(rbind, XML::xmlToList("../museums/haum/trans.xml")))
dat$a <- as.numeric(dat$a) dat$a <- as.numeric(dat$a)
dat$b <- as.numeric(dat$b) dat$b <- as.numeric(dat$b)
@ -16,7 +16,7 @@ plot(ty ~ tx, dat, xlim = c(0, 3840), ylim = c(0, 2160))
# read log data # read log data
datlogs <- read.table("../data/haum/event_logfiles_metadata_2023-09-23_01-31-30.csv", datlogs <- read.table("results/haum/event_logfiles_metadata_2023-09-23_01-31-30.csv",
sep = ";", header = TRUE) sep = ";", header = TRUE)
datlogs$date <- as.Date(datlogs$date) datlogs$date <- as.Date(datlogs$date)
datlogs$date.start <- as.POSIXct(datlogs$date.start) datlogs$date.start <- as.POSIXct(datlogs$date.start)