nteract / scrapbook

A library for recording and reading data in notebooks.
https://nteract-scrapbook.readthedocs.io
BSD 3-Clause "New" or "Revised" License
281 stars 26 forks source link

a few examples in docs #66

Closed choldgraf closed 4 years ago

choldgraf commented 4 years ago

Hello 👋 per some of my experiences in #65 , I thought it would be helpful to add two examples to the documentation. This PR does the following:

  1. Adds code to demonstrate a custom encoder with a simple Altair example
  2. Adds code to demonstrate using the display encoder with Matplotlib figures
  3. Adds a link to the docs in the README because I missed it the first time :-)

Let me know if this is helpful, or if folks would like to see changes!

closes #65

codecov[bot] commented 4 years ago

Codecov Report

Merging #66 into master will not change coverage. The diff coverage is n/a.

@@          Coverage Diff           @@
##           master     #66   +/-   ##
======================================
  Coverage    96.5%   96.5%           
======================================
  Files          10      10           
  Lines         486     486           
======================================
  Hits          469     469           
  Misses         17      17
MSeal commented 4 years ago

Thanks for posting the PR -- I'll let you read the comments I left on the issue and see how you'd want to update the doc additions.

choldgraf commented 4 years ago

Looking at your comments, I think that these doc additions could be useful. This PR gives an example that shows off the pattern that you suggested (using 'display' to store only the display information), as well as another example to show how to create a custom encoder that stores information about the plot itself. I think both examples would have helped me come to this conclusion more quickly. What do you think?