This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Error in FUN(left, right) : non-numeric argument to binary operator in RStudio

Hello

I'm having a problem that I get the message

Error in FUN(left, right) : non-numeric argument to binary operator in R

This is the code that I'm using for my data

library(vegan)
logespecies2mm <- log(especies2mm+1)

I really appreciate all the help, I have the script if you want more detail but the main goal is that I want to do a RDA graph analysis in two sampling times to answer a question in correlation sorting (sand particles grain size) with the abundance of two main groups bivalves and gastropods. Also I been trying to transform the data without using log, instead use hellinger transformation but in my RStudio it says hellinger object error not found in R. Really appreciate all the help

rstudio

You really think people can troubleshoot this without knowing anything at all about what's in the especies2mm object?

1 answer

Your data.frame is not of type double (numeric) or integer so you cannot apply a mathematical / log transformation function:

> log2(data.frame(A="A")+1)
Error in FUN(left, right) : non-numeric argument to binary operator

https://stackoverflow.com/questions/2288485/how-to-convert-a-data-frame-column-to-numeric-type

Log in to answer this question.