# NOT RUN {
## Load package
library("SPUTNIK")
## Create the msi.dataset-class object
sz <- c(5, 4)
x <- matrix(rnorm(sz[1] * sz[2] * 20), sz[1]*sz[2], 20)
mz <- sort(sample(100, ncol(x)))
msiX <- msiDataset(x, mz, sz[1], sz[2])
## Binarize the reference image
refBin <- binKmeans(msiX)
## Plot the binarized reference
plot(refBin)
# }
Run the code above in your browser using DataLab