Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • How to identify which packages a code is using

    Hi!

    I am currently replicating some papers using replication packages. The problem is that sometimes the authors do not specify which packages they are using, and I therefore need to run the code until an error appears, to install the corresponding package. Once this is done, I have to run it again and again until I have installed all the unmentioned packages. I was wondering if there is a way to know in advance which packages the code is using.

    Thanks for the help!
    Sergi

  • #2
    The question is phrased in terms of packages but Stata certainly has no way to know what packages are being used if package names don''t match one-to-one the names of commands they contain.

    Knowing in advance unfortunately depends on authors documenting what they use. Practices vary here over the entire possible range from documenting everything to documenting nothing.

    In a way it's a compliment to Stata that community-contributed commands look like official commands in many ways There are many examples here on Statalist of authors forgetting that something long familiar is in fact community-contributed, or regarding it, apparently, as obvious or well known.

    I don't know an easy way to do this. In principle there can't be a definitive list of all possible packages or community-contributed commands anywhere -- that is, anyone could write a command now that isn't public until the instant it is distributed -- and there isn't in practice an easy way to identify official commands as the complementary set (commands can be abbreviated in some cases, commands aren't necessarily the first word in a command line, command names can occur as part of other text).

    Comment

    Working...
    X