[R] Trimming blanks from the ends of strings

Jason Turner jasont at indigoindustrial.co.nz
Fri Jun 1 04:16:44 CEST 2001


> I want to remove
> the spaces from the ends so I can use them right justified (adj=1) as labels on
> the vertical axis of a graph. 

gsub("[ ]*$","",my.data.object)

Cheers

Jason
-- 
Indigo Industrial Controls Ltd.
64-21-343-545
jasont at indigoindustrial.co.nz
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._



More information about the R-help mailing list