-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
change UB Exam Dataset to Local Exam Dataset
- Loading branch information
1 parent
4f0342f
commit a1a40a7
Showing
15 changed files
with
79 additions
and
79 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,36 +1,29 @@ | ||
# set working directory | ||
#setwd("~/Downloads/EttuBench") | ||
|
||
# load two files evaluation.R and utils.R | ||
source(file = "./evaluation.R") | ||
source(file = "./utils.R") | ||
|
||
# load supporting libraries | ||
library(cluster) | ||
library(factoextra) | ||
library(RColorBrewer) | ||
|
||
dataset <- read.csv(file = "./data/bombay_queries.csv", header = TRUE, sep = "\t") | ||
|
||
distMat <- readDistMat("./data/bombay_aligon.csv") | ||
silhouettePlot(distMat, dataset$label, "./figure/sil_bombay_Aligon.pdf") | ||
|
||
distMat <- readDistMat("./data/bombay_aligon_regularization.csv") | ||
silhouettePlot(distMat, dataset$label, "./figure/sil_bombay_Aligon_regularization.pdf") | ||
|
||
dataset <- read.csv(file = "./data/ub_queries.csv", header = TRUE, sep = "\t") | ||
|
||
distMat <- readDistMat("./data/ub_aligon.csv") | ||
silhouettePlot(distMat, dataset$label, "./figure/sil_ub_Aligon.pdf") | ||
|
||
distMat <- readDistMat("./data/ub_aligon_regularization.csv") | ||
silhouettePlot(distMat, dataset$label, "./figure/sil_ub_Aligon_regularization.pdf") | ||
|
||
dataset <- read.csv(file = "./data/googleplus_queries.csv", header = TRUE, sep = "\t") | ||
|
||
distMat <- readDistMat("./data/googleplus_aligon.csv") | ||
silhouettePlot(distMat, dataset$label, "./figure/sil_googleplus_Aligon.pdf") | ||
|
||
distMat <- readDistMat("./data/googleplus_aligon_regularization.csv") | ||
silhouettePlot(distMat, dataset$label, "./figure/sil_googleplus_Aligon_regularization.pdf") | ||
|
||
library(ggplot2) | ||
|
||
comparison <- read.csv(file = "./data/result.csv", header = TRUE) | ||
comparison$dataset <- factor(comparison$dataset, | ||
levels = c("IIT Bombay Dataset", | ||
"Local Exam Dataset", | ||
"PocketData-Google+")) | ||
|
||
ggplot(data = comparison, aes(x = metric, y = silhouette, fill = regularization)) + | ||
geom_bar(position="dodge", stat="identity") + facet_grid(~ dataset) + | ||
ylab("Average Silhouette Coefficient") + xlab("Metric") + | ||
theme_bw(base_size = 18) + theme(legend.position = "top") + scale_fill_grey() + | ||
ggsave(filename = "./figure/compare_silhouette.pdf") | ||
|
||
ggplot(data = comparison, aes(x = metric, y = beta_cv, fill = regularization)) + | ||
geom_bar(position="dodge", stat="identity") + facet_grid(~ dataset) + | ||
ylab("Average Silhouette Coefficient") + xlab("Metric") + | ||
theme_bw(base_size = 18) + theme(legend.position = "top") + scale_fill_grey() + | ||
ggsave(filename = "./figure/compare_betacv.pdf") | ||
|
||
ggplot(data = comparison, aes(x = metric, y = dunn, fill = regularization)) + | ||
geom_bar(position="dodge", stat="identity") + facet_grid(~ dataset) + | ||
ylab("Average Silhouette Coefficient") + xlab("Metric") + | ||
theme_bw(base_size = 18) + theme(legend.position = "top") + scale_fill_grey() + | ||
ggsave(filename = "./figure/compare_dunn.pdf") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,29 +1,36 @@ | ||
# set working directory | ||
#setwd("~/Downloads/EttuBench") | ||
|
||
# load two files evaluation.R and utils.R | ||
source(file = "./evaluation.R") | ||
source(file = "./utils.R") | ||
|
||
# load supporting libraries | ||
library(ggplot2) | ||
|
||
comparison <- read.csv(file = "./data/result.csv", header = TRUE) | ||
comparison$dataset <- factor(comparison$dataset, | ||
levels = c("IIT Bombay Dataset", | ||
"UB Exam Dataset", | ||
"PocketData-Google+")) | ||
|
||
ggplot(data = comparison, aes(x = metric, y = silhouette, fill = regularization)) + | ||
geom_bar(position="dodge", stat="identity") + facet_grid(~ dataset) + | ||
ylab("Average Silhouette Coefficient") + xlab("Metric") + | ||
theme_bw(base_size = 18) + theme(legend.position = "top") + scale_fill_grey() + | ||
ggsave(filename = "./figure/compare_silhouette.pdf") | ||
|
||
ggplot(data = comparison, aes(x = metric, y = beta_cv, fill = regularization)) + | ||
geom_bar(position="dodge", stat="identity") + facet_grid(~ dataset) + | ||
ylab("Average Silhouette Coefficient") + xlab("Metric") + | ||
theme_bw(base_size = 18) + theme(legend.position = "top") + scale_fill_grey() + | ||
ggsave(filename = "./figure/compare_betacv.pdf") | ||
|
||
ggplot(data = comparison, aes(x = metric, y = dunn, fill = regularization)) + | ||
geom_bar(position="dodge", stat="identity") + facet_grid(~ dataset) + | ||
ylab("Average Silhouette Coefficient") + xlab("Metric") + | ||
theme_bw(base_size = 18) + theme(legend.position = "top") + scale_fill_grey() + | ||
ggsave(filename = "./figure/compare_dunn.pdf") | ||
library(cluster) | ||
library(factoextra) | ||
library(RColorBrewer) | ||
|
||
dataset <- read.csv(file = "./data/bombay_queries.csv", header = TRUE, sep = "\t") | ||
|
||
distMat <- readDistMat("./data/bombay_aligon.csv") | ||
silhouettePlot(distMat, dataset$label, "./figure/sil_bombay_Aligon.pdf") | ||
|
||
distMat <- readDistMat("./data/bombay_aligon_regularization.csv") | ||
silhouettePlot(distMat, dataset$label, "./figure/sil_bombay_Aligon_regularization.pdf") | ||
|
||
dataset <- read.csv(file = "./data/ub_queries.csv", header = TRUE, sep = "\t") | ||
|
||
distMat <- readDistMat("./data/ub_aligon.csv") | ||
silhouettePlot(distMat, dataset$label, "./figure/sil_ub_Aligon.pdf") | ||
|
||
distMat <- readDistMat("./data/ub_aligon_regularization.csv") | ||
silhouettePlot(distMat, dataset$label, "./figure/sil_ub_Aligon_regularization.pdf") | ||
|
||
dataset <- read.csv(file = "./data/googleplus_queries.csv", header = TRUE, sep = "\t") | ||
|
||
distMat <- readDistMat("./data/googleplus_aligon.csv") | ||
silhouettePlot(distMat, dataset$label, "./figure/sil_googleplus_Aligon.pdf") | ||
|
||
distMat <- readDistMat("./data/googleplus_aligon_regularization.csv") | ||
silhouettePlot(distMat, dataset$label, "./figure/sil_googleplus_Aligon_regularization.pdf") | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters