I want to perform adonis analysis in R using the Bray-curtis matrix that I have. I do not know what the error is that I am getting.
I am using the following codes:
Just a note, I also do downstream analysis in R with tidyverse and vegan, and they use different data structures. Vegan expects base r data.frames (with row names and column names), while tidyverse uses the tidyverse data structures (like tibbles without row names and column names) and this trips me up all the time...
Thank you for your comment.
The error that I've got is the following:
Error in contrasts<-(*tmp*, value = contr.funs[1 + isOF[nn]]) :
contrasts can be applied only to factors with 2 or more levels
Exactly. As you said there is something wrong regarding the row names and column names.
When I use "inner_join" function it gives me:
# A tibble: 0 x 62 # ... with 62 variables: sample_id <chr>, Farm <chr>, Variety <chr>, Treat <chr>,
......