R/reorderImage.R

Defines functions reorderImage

Documented in reorderImage

reorderImage<-function(IM,oldClu,newClu){
if(crand2(oldClu,newClu)!=1)stop("Old and new clu's are not compatibale (crand index is not 1)!\n")
newOrder<-which(table(oldClu,newClu)>0,arr.ind=TRUE)[,1]
return(IM[newOrder,newOrder])
}

Try the blockmodeling package in your browser

Any scripts or data that you put into this service are public.

blockmodeling documentation built on May 31, 2017, 4:11 a.m.