Richard-- Nice. If I understand your code correctly, in the line
ddm <- matrix("", (n+2) %/% nc, nc) I could instead use ddm <- matrix("", (n + nc - 1) %/% nc, nc) for generalizability, as I may have to increase nc as the list of words grows ever longer. Thanks everyone. Several good suggestions. --Chris Ryan Richard M. Heiberger wrote: > n <- length(dd) > ddm <- matrix("", (n+2) %/% nc, nc) > ddm[1:n] <- dd ______________________________________________ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.