[R] Truncating leading zeros in strings
E. Paul Wileyto
epw at mail.med.upenn.edu
Thu Oct 7 15:57:51 CEST 2010
I am new to R. I thing this will be simple, but I don't yet know my way
around.
I am generating character strings from the system clock that represent
integers, and I want to convert them to integer values. Strtoi works
well, except when there are leading zeros on the string. Could anyone
suggest a way to remove those leading zeros?
Thanks
Paul
--
E. Paul Wileyto, Ph.D.
Assistant Professor of Biostatistics
Tobacco Use Research Center
School of Medicine, U. of Pennsylvania
3535 Market Street, Suite 4100
Philadelphia, PA 19104-3309
215-746-7147
Fax: 215-746-7140
epw at upenn.edu
More information about the R-help
mailing list