data(perception)
res.id <- smacofIndDiff(perception, constraint = "identity") ## identity restricted weights
summary(res.id)
res.id$cweights
plot(res.id)
plot(res.id, type = "p", pch = 25, col = 4, label.conf = list(label = TRUE, pos = 3, col = 4))
res.diag <- smacofIndDiff(perception, constraint = "indscal") ## diagonally restricted weights
res.diag$cweights
plot(res.diag)
plot(res.diag, type = "p", pch = 25, col = 4, label.conf = list(label = TRUE, pos = 3, col = 4))
res.idio <- smacofIndDiff(perception, constraint = "idioscal") ## IDIOSCAL
Wk <- res.idio$cweights
G <- res.idio$gspace
G
G
data(helm)
res.helm <- smacofIndDiff(helm, constraint = "indscal")
plot(res.helm, plot.type = "confplot")
barplot(sort(res.helm$sps, decreasing = TRUE), main = "Stress per Subject", cex.names = 0.8)
plot(res.helm, plot.type = "bubbleplot")
plot(res.helm, plot.type = "stressplot")
plot(res.helm, plot.type = "Shepard")
plot(res.helm, plot.type = "resplot")
## idioscal and indscal with starting configurations:
startconf <- matrix(rnorm(20), 10, 2)
idioscal(helm, init = startconf)
indscal(helm, init = startconf)
Run the code above in your browser using DataLab