Thanks for your comments!
Hi,
I tried merging two data frames (One_17#20, Two_18#30) using the R merge function this way:
x <- merge(One_17#20, Two_18#30)
I got the following error:
Error in merge(One_17) : object 'One_17' not found.
I thought this might be due to the long names with underscore/# character. Does anyone know the way around this problem?
Thanks
2 answers
That # is a comment character, the system only sees merge(One_17 and I'm surprised it didnt give the error missing ), that might have been next if there was a variable named One_17
You can't use # in variable names in many programming languages.
As karl.stamm mentioned, don't use # in variable names (in general, don't use symbols other than "_", which I'm sure is also a special character in some language I've never used). If you must, though, then
x <- merge(`One_17#20`, `Two_18#30`)
will do what you want.
Log in to answer this question.
This is not a bioinformatics question.