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]

Re: st: profile.do file


From   Nick Cox <[email protected]>
To   "[email protected]" <[email protected]>
Subject   Re: st: profile.do file
Date   Wed, 27 Nov 2013 17:23:00 +0000

As Glenn expects to remember the names of the programs he defines,
there is no loss and some gain in just defining them in separate
files.
Nick
[email protected]


On 27 November 2013 17:17, Stas Kolenikov <[email protected]> wrote:
> Glenn, my F4 shortcut is going to kill all of these! [evil laughter]
>
> I found it problematic to put programs in the profile.do, as I
> repeatedly -discard- or -program drop _all- within my do-files, just
> to make sure that they can run fully independently on their own legs.
>
> -- Stas Kolenikov, PhD, PStat (ASA, SSC)
> -- Senior Survey Statistician, Abt SRBI
> -- Opinions stated in this email are mine only, and do not reflect the
> position of my employer
> -- http://stas.kolenikov.name
>
>
>
> On Wed, Nov 27, 2013 at 11:07 AM, Glenn Hoetker <[email protected]> wrote:
>> My profile.do consists of several shortcuts for things I either do repeatedly or can never remember the context for:
>>
>>
>> // To display all the dta files in the current directory
>> capture program drop dta
>> program define dta
>>         ls *.dta
>> end
>>
>> // To display all the do files in the current directory
>> capture program drop ddo
>> program define ddo
>>         ls *.do
>> end
>>
>> // To open the current directory in the Finder (may need to be tweaked for other than Mac)
>> capture program drop oo
>> program define oo
>>         !open .
>> end
>>
>>
>> //To turn trace on.  Optionally, "stn #" sets tracedepth to #. Otherwise, it leaves it unchanged.
>> capture program drop stn
>> program define stn
>>         if "`1'" != "" {
>>          set tracedepth `1'
>>         }
>>         set trace on
>> end
>>
>> //Turn trace off
>> capture program drop stf
>> program define stf
>>         set trace off
>> end
>>
>> //Edit the profile.do file, since I can never remember where it is
>> capture program drop editprofile
>> program define editprofile
>>          doedit "/Users/ghoetker/Library/Application Support/Stata/profile.do"
>> end
>>
>>
>>
>> Glenn Hoetker
>> Arizona State University | W. P. Carey School of Business
>> Dean's Council Distinguished Scholar & Associate Professor
>> Affiliate Professor   Sandra Day O'Conner College of Law
>> Senior Sustainability Scholar   Global Institute of Sustainability
>> Faculty Fellow   Center for Science, Law & Innovation
>> [email protected]  | http://hoetker.faculty.asu.edu | 480-965-4566
>>
>>
>>
>> *
>> *   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/
*
*   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