Re: [R] paste - eliminate spaces?

From: Doran, Harold <HDoran_at_air.org>
Date: Thu 26 Jan 2006 - 06:02:00 EST


Try

paste('test',1,sep='')

-----Original Message-----
From: r-help-bounces@stat.math.ethz.ch
[mailto:r-help-bounces@stat.math.ethz.ch] On Behalf Of r user
Sent: Wednesday, January 25, 2006 1:58 PM To: rhelp
Subject: [R] paste - eliminate spaces?

I am trying to combine the value of a variable and text.

e.g.
I want "test1", with no spaces.

I try:

h=1
paste('test',1)

But get:
[1] "test 1"

(i.e. there is a space between "test'" and "1")

Is there a way to eliminate the space?



R-help@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide!
http://www.R-project.org/posting-guide.html

R-help@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html Received on Thu Jan 26 06:27:55 2006

This archive was generated by hypermail 2.1.8 : Thu 26 Jan 2006 - 08:28:21 EST