Bookmark and Share

Notice: On March 31, it was announced that Statalist is moving from an email list to a forum. The old list will shut down at the end of May, and its replacement, statalist.org is already up and running.


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

Re: st: Batch renaming variables


From   Wameq Raza <wameq.r@gmail.com>
To   statalist@hsphsun2.harvard.edu
Subject   Re: st: Batch renaming variables
Date   Thu, 18 Oct 2012 15:48:23 +0200

Thanks Saqlain,
I'm aware of this syntax. The reason for my email was to get help
regarding the mass edit. I have 45 of such variables and would be
interested in not doing this manually.
Best
Wameq


On Thu, Oct 18, 2012 at 3:44 PM, saqlain raza <bhatti_sb@yahoo.com> wrote:
> try with rename v1 cost_a
>
>
>
> Saqlain RAZA
>
>
> ________________________________
> From: Wameq Raza <wameq.r@gmail.com>
> To: statalist@hsphsun2.harvard.edu
> Sent: Thursday, October 18, 2012 3:36 PM
> Subject: st: Batch renaming variables
>
> Hi everyone,
> I'm having some trouble trying to figure out how to do batch renames.
> To elaborate, suppose I have 10 variables: v1, v2....v10 and I want to
> rename every second var (ie v2, v4, v6, v8 and v10) to cost_a,
> cost_b....cost_e. Can anyone please help me figure this out? I've
> tried looking into renvars, but can't seem to figure it out.
> Thanks!
> Wameq
>
> --
> W A M E Q   R A Z A
> *
> *   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/



-- 
W A M E Q   R A Z A
*
*   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–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   Site index