Hanne Ballestad <hanne.ballestad <at> bio.uio.no> writes: > I am trying to analyse my data using amova > (http://www.oga-lab.net/RGM2/func.php?rd_id=pegas:amova): > > My input to R is a DNA sequence file, format=fasta > dna<- read.dna("XX.fasta", format="fasta") #left other options as > default > d<- dist.dna(dna, model="raw") > g<- read.table("XXX.design") > > Load necessary libraries: > library(pegas)
[snip] > Running Amova: > amova(d ~ g, nperm = 100) > Error in FUN(X[[1L]], ...) : 'bin' must be numeric or a factor > > How can I solve this "bin" problem? [snip] > My input file for g looks like this: > > sequenceA 1 > sequenceB 1 > sequenceC 1 [snip] > I think the "proper manual" you're looking for is actually the introductory R material -- try looking at the Introduction to R that comes with R. You can look up specific commands such as "c" and "rep" by using ?c or ?rep . I'm not sure of the structure of your data, but I think you probably want g[[2]] (i.e. the second column of g) as your predictor variable. You might get more specific help on the bioconductor mailing list. ______________________________________________ R-help@r-project.org mailing list 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.