Closed hkaspersen closed 8 months ago
Hi Hakon
ord_calc is converting the logical variable antibiotic into a numeric (dummy) variable with levels 0 (false) and 1 (true). ord_calc can't handle factor or character variables as constraints.
microViz doesn't have a way of plotting centroids for factor constraints, if that is what you are after? You could look at vegan's own ordination calculation and plotting functionality, e.g. with cca and plot if you want this.
Thanks for the clarification! I was only interested in plotting it as a character variable on the dots, so that I can see which ones are true and which are false properly. I fixed it by creating another column with the same data and used that one to plot instead, and that worked fine.
I am using the following code to generate a CCA plot:
The "antibiotic" variable is a TRUE/FALSE variable, and in the plot I was hoping to be able to plot this TRUE/FALSE relationship. However, in the plot the value becomes numeric. Is this something that happens in the CCA analysis? How can I fix this?