### Assume the file sample1 and phylo1 have been 
### saved to the R working directory.
### The phylocom executable file has been copied 
### to the same working directory
### Or could be invoked in console by command lines.
### in order to run phylocom in R, simply copy the 
### following command:
#   i = 1
#   phylocom.comstruct(sample = paste("sample",i, sep = ""),
#            phylo = paste("phylo",i, sep = ""), 
#            swapmethod = 2, runs = 999, swaps = 1000, aw = TRUE,  
#            file = paste("comstruct.aw",   i,".txt", sep = ""))
Run the code above in your browser using DataLab