You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
are Signalcommands the only commands where package name != command name? #60
I wanted to implement your stata scanner without having to deploy stata, i.e. just read the source code and go through a list of keywords. is this a futile approach?
is what one would use to pick up stata commands which do not bear the name of their package.
suppose I get
ssc hot, n(1000)
Could I reasonably assume (yes there will some errors, but fine) that for the 1000-20 (files in that list) I can confront a user's code with my list of 980 patterns, and say if I match binscatter, I could claim that you are using the binscatter package (see net describe binscatter, from(http://fmwww.bc.edu/RePEc/bocode/b))
ok i see - that's what I thought/hoped. I'm looking into this right now. Not sure I understand why one needs the bag of word approach here, can you explain? Is it because some package/command names are plain english words which you would also find in a sentence? My idea was that I only look at the code files, so I don't have to worry about english prose and can forget about the context of the word. So then, if I find binscatter I can be sure that this a stata command and not an english word (well let's assume that word existed).
I'm implemeting this in julia, there's plenty of tools around as well.
Activity
larsvilhuber commentedon May 23, 2025
Background on the Stata scanner:
So the right place to fix this is in https://github.com/labordynamicsinstitute/ssc-mirror/, to there generate a list of keyword-package crosswalks as an output, and store it in the
releasesbranch.Some of this has been addressed (as a dead-end branch) in the
statsbranch of that repo https://github.com/labordynamicsinstitute/ssc-mirror/tree/statslarsvilhuber commentedon May 23, 2025
A further note on the Stata scanner:
floswald commentedon May 23, 2025
ok i see - that's what I thought/hoped. I'm looking into this right now. Not sure I understand why one needs the bag of word approach here, can you explain? Is it because some package/command names are plain english words which you would also find in a sentence? My idea was that I only look at the code files, so I don't have to worry about english prose and can forget about the context of the word. So then, if I find
binscatterI can be sure that this a stata command and not an english word (well let's assume that word existed).I'm implemeting this in julia, there's plenty of tools around as well.
larsvilhuber commentedon May 23, 2025
There are signal words that are plain english word (table, etc.) because people have chosen that for ado files.
IMHO, Julia is not the right tool for something that is pure text processing, but knock yourself out.
larsvilhuber commentedon Jan 19, 2026
@floswald Did you do this in a way that I could pull into this workflow?
floswald commentedon Jan 19, 2026
nope sorry...