x<-woodmouse[sample(15, size=110, replace=TRUE), ]
Unfortunately, the haplotypes are rather opaquely numbered by Roman numerals and makes it difficult to figure out where these samples came from. The attribute function above tells you which sequences in x make up which haplotypes in h but it's a bit tedious, particularly when dealing with large data sets. To combat this, I've written a function to label each of the haplotypes with the name given in the original DNAbin object:
'hap' is the haplotype/DNAbin object obtained from running haplotype, while 'dat' is the original DNAbin object.
for(i in 1:dim(hap)) attr(hap, "dimnames")[][i]<-nam[attr(hap, "index")[[i]]]
Let me know how it goes...