Thanks Brian,
I guess I wasn't clear enough. I want to be able to execute code within a
cell that gets the JSON for the current notebook. Here's the best I can do
currently. It almost works, but I don't know how to get the name of the
current notebook:
```
import nbformat
fp = open('TheNameOfThisWorkbook.ipynb')
nb = nbformat.read(fp, 4)
for cell in nb['cells']:
print('---')
print(cell)
```
On Tue, Jul 11, 2017 at 3:34 PM, Brian Granger <[email protected]> wrote:
> In the file browser of JupyterLab, right click on the file and "Open
> With" the "Editor"
>
> On Tue, Jul 11, 2017 at 3:31 PM, Sterling Paramore <[email protected]>
> wrote:
> > Is there a way to get the JSON representation of a notebook that is
> > currently open that could be passed to nbformat?
> >
> > I'm trying to create a pandas dataframe from a markdown cell with a
> table in
> > it. This is kind of a hack workaround for having some way of easily
> editing
> > and pretty-printing dataframes within a notebook.
> >
> > Thanks,
> > Sterling
> >
> > --
> > You received this message because you are subscribed to the Google Groups
> > "Project Jupyter" group.
> > To unsubscribe from this group and stop receiving emails from it, send an
> > email to [email protected].
> > To post to this group, send email to [email protected].
> > To view this discussion on the web visit
> > https://groups.google.com/d/msgid/jupyter/9d0f6ae5-0e9a-
> 4500-acba-51ead21f032c%40googlegroups.com.
> > For more options, visit https://groups.google.com/d/optout.
>
>
>
> --
> Brian E. Granger
> Associate Professor of Physics and Data Science
> Cal Poly State University, San Luis Obispo
> @ellisonbg on Twitter and GitHub
> [email protected] and [email protected]
>
> --
> You received this message because you are subscribed to the Google Groups
> "Project Jupyter" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To post to this group, send email to [email protected].
> To view this discussion on the web visit https://groups.google.com/d/
> msgid/jupyter/CAH4pYpTE4QjgjxzLZSoRh0OyJk8rYBFOQ2Bxt04Vo1feayRymA%40mail.
> gmail.com.
> For more options, visit https://groups.google.com/d/optout.
>
--
You received this message because you are subscribed to the Google Groups
"Project Jupyter" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/jupyter/CAO3qWJOXfSLDPpbHR5P3ypkE0K_sJz35wSZCUsvG9%2B5PbCnLwA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.