data("SupremeCourt")
# a matrix with joint probability of disagreement
SupremeCourt
# show judges in original alphabetical order
d <- as.dist(SupremeCourt)
pimage(d, diag = TRUE, upper = TRUE)
# reorder judges using seriation based on similar decisions
o <- seriate(d)
o
pimage(d, o, diag = TRUE, upper = TRUE)
# Use optimal leaf ordering (hierarchical clustering with reordering)
# which uses a dendrogram
o <- seriate(d, method = "OLO")
o
plot(o[[1]])
# Use multi-dimensional scaling and show the configuration
o <- seriate(d, method = "sammon")
o
pimage(d, o, diag = TRUE, upper = TRUE)
plot_config(o[[1]])
Run the code above in your browser using DataLab