Skip to content

Commit

Permalink
Added wordcloud image and notebook
Browse files Browse the repository at this point in the history
  • Loading branch information
mwouts committed Nov 23, 2019
1 parent db544c9 commit 452aab6
Show file tree
Hide file tree
Showing 5 changed files with 66 additions and 0 deletions.
2 changes: 2 additions & 0 deletions README.md
Expand Up @@ -15,6 +15,8 @@ It can also convert these documents **into** Jupyter
Notebooks, allowing you to synchronize content in both
directions.

![](docs/jupytext_word_cloud.png)

The languages that are currently supported by Jupytext are: Julia, Python, R, Bash, Scheme, Clojure, Matlab, Octave, C++, q/kdb+, IDL, TypeScript, Javascript, Scala, Rust/Evxcr, PowerShell and Robot Framework. Extending Jupytext to more languages should be easy - read more at [CONTRIBUTING.md](https://github.com/mwouts/jupytext/blob/master/CONTRIBUTING.md). In addition, jupytext users can choose between two formats for notebooks as scripts:
- The `percent` format, compatible with several IDEs, including Spyder, Hydrogen, VScode and PyCharm. In that format, cells are delimited with a commented `%%`.
- The `light` format, designed for this project. Use that format to open standard scripts as notebooks, or to save notebooks as scripts with few cell markers - none when possible.
Expand Down
1 change: 1 addition & 0 deletions binder/requirements.txt
Expand Up @@ -2,6 +2,7 @@ jupytext>=1.2.0rc0
jupyterlab>=1.0
plotly
matplotlib
wordcloud
pandas
wbdata
bash_kernel
61 changes: 61 additions & 0 deletions demo/Jupytext's word cloud.py
@@ -0,0 +1,61 @@
# This is a notebook that I used to generate Jupytext's word cloud.
# To open this script as a notebook in JupyterLab, right-click on this file, and select _Open with/Notebook_.

from wordcloud import WordCloud

text = """
Jupytext
Notebook
JupyterLab
Git
GitHub
Version control
Markdown
R Markdown
Text
Scripts
Code
Notebook Template
Binder
Visual Studio Code
PyCharm
Atom
Spyder
Hydrogen
RStudio
Sphinx-Gallery
Documentation
black
pytest
autopep8
Metadata
Reproducible research
R
Julia
Python
Bash
Powershell
Scala
Scheme
Clojure
Matlab
Octave
C++
q/kdb+
IDL
TypeScript
Javascript
Scala
Rust
Robot Framework
"""

wordcloud = WordCloud(
random_state=1,
background_color='white',
width=1200, height=500
).generate_from_frequencies({word: 1 for word in text.splitlines()})

wordcloud.to_image()

wordcloud.to_file('../docs/jupytext_word_cloud.png')
2 changes: 2 additions & 0 deletions docs/index.md
@@ -1,5 +1,7 @@
# Jupyter notebooks as Markdown documents, Julia, Python or R scripts

![](jupytext_word_cloud.png)

## Contents

* [Introduction](introduction)
Expand Down
Binary file added docs/jupytext_word_cloud.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 452aab6

Please sign in to comment.