Statalist The Stata Listserver

[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

Re: st: trim spaces in postcode

From   "Emma Slaymaker" <>
To   <>
Subject   Re: st: trim spaces in postcode
Date   Fri, 31 Mar 2006 14:19:42 +0100

Hi Maurizio,

I'm probably being too simplistic but doesn't this do the job:

gen str8 newvar=subinstr(oldvar," ","",.)

if oldvar is your current postcode variable and newvar is a new one.



>>> 31/03/06 13:55:54 >>>
I am trying to trim all the spaces in a code, in particular an english
unit postcode
but I still haven't found the correct way. I downloaded the ptseed
strip function but seems is not working.
Can anyone please help me? The database I am working on is quite
Thank you..
maurizio gibin
*   For searches and help try:
*   For searches and help try:

© Copyright 1996–2023 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index