Comments (6)
Not necessarily syntax-compatible in a strict sense, but just sort of in a similar spirit. I guess the main goal I have in mind is that it be easy/natural for Stata users to learn and remember the syntax.
Anyway, whoops, I may have jumped the gun (but I had other work that I urgently need to procrastinate on, apparently): I went ahead and pushed a version of this. We can always revise the syntax later, though. Let me know how it strikes you in practice, or if you bump into any other issues.
from nbstata.
Thanks! I'll give it a go and report back in a few days after I've got my current data analysis project off my desk and can update the kernel without tempting Murphy's law.
from nbstata.
Finally had a chance to test this and it seems to be working great—thanks!
from nbstata.
I like this. The only thing I'm pondering is the syntax. It's rare for Stata commands to have a frame(someframe)
option (maybe only frlink
?). And I don't think they'd ever allow if somevariable == 1
for a variable not present in the current frame. Like we could do %browse frame someframe: if somevariable == 1
or %frame_browse someframe: if somevariable == 1
, but I'm not sure either is an improvement. %frame someframe: browse if somevariable == 1
or %frame someframe: %browse if somevariable == 1
?
from nbstata.
I'm leaning toward:
%frbrowse framename[: [varlist] [if] [in] [, nolabel noformat]]
edit: I'm not sure how to best indicate this in the syntax diagram, but %frbrowse framename
is valid as the most basic call.
from nbstata.
Is the design goal to keep the magic syntax-compatible with the underlying stata command?
Because if that is the objective, a generic %frame
prefix for magics would probably be nice and modular:%frame framename: %browse…
, but equally %frame framename: %head…
Another possiblity that occurred to me would be a %frame
magic that was the equivalent of wrapping the cell in frame framename { }
but also worked on magics—but that would do unexpected things if the notebook was exported to a .do
file, so I suspect is not a good idea.
from nbstata.
Related Issues (20)
- Kernel crashes with certain comments HOT 1
- Request: conda-forge package HOT 1
- invalid config options HOT 2
- `%help` triggers an unhandled error
- Ease setting figure dimensions in-line HOT 3
- %head fails with "head failed. must be real number, not str" HOT 7
- New animated gif, specific to nbstata HOT 1
- XDG spec for config files HOT 7
- Tabs vs Spaces HOT 8
- Add config file location to %status magic output
- Add a Stata Quarto tutorial HOT 5
- Improve ability to initialize Stata automatically HOT 1
- Display config file errors in notebook HOT 7
- Config file saved at custom location (by `install --prefix`) ignored
- Add docs about using as alternative to 'stata_setup' package
- nbstata compiles document but does not work in interactive mode in quarto documents (in RStudio) HOT 5
- Broken link in documentation HOT 1
- Stata 18.5/Now support
- RStudio + Quarto Error HOT 3
- Can't find the stata installation path HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from nbstata.