Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

st: RE: String match(strmatch) for case insensitive


From   Timothy King <[email protected]>
To   "[email protected]" <[email protected]>
Subject   st: RE: String match(strmatch) for case insensitive
Date   Mon, 3 Feb 2014 16:41:40 +0000

Hi Veeresh,

I'm sure other Stata users will suggest better solutions. However, it is simple to convert to lower case for one or more vars. For example, I just wrote the following loop in which title is the string variable(s):

local title title
foreach var of varlist title{
gen title1=lower(`var')
}

Hope this helps,

Dr Tim King
Leeds University Business School
________________________________________
From: [email protected] [[email protected]] On Behalf Of Veeresh Thummadi [[email protected]]
Sent: 03 February 2014 16:33
To: [email protected]
Subject: st: String match(strmatch) for case insensitive

Hi

I am looking if i can make a strmatch for strings so that it can be
case insensitive. I don't want to use the upper or lower case
conversion as it appears to be tedious. Is there a way out for case
insensitive strings?

Thanks
Veeresh

Veeresh Thummadi
Research scientist
Stern School of business
New York University
*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/faqs/resources/statalist-faq/
*   http://www.ats.ucla.edu/stat/stata/
*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/faqs/resources/statalist-faq/
*   http://www.ats.ucla.edu/stat/stata/


© Copyright 1996–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index