rgenomerda

How to make rownames in two separate data.frames the same?


Please see the picture attached! I am trying to conduct a RDA analysis, but before I proceed I need to make sure my SNP dataset and my Environmental dataset have identical rownames. I tried editing the individual datasets in excel to satisfy this requirement, and after seemingly making them the same (there is no difference between the rownames anymore), when i type in: identical(rownames(gen), env) It still states the rownames matching is "FALSE" when it clearly isn't. Can anyone help with this?


Solution

  • It seems a small typo error. Please try this:

    identical(rownames(gen), rownames(env))