1 + 1
2
Quarto enables you to weave together content and executable code into a finished document. To learn more about Quarto see https://quarto.org.
When you click the Render button a document will be generated that includes both content and the output of embedded code. You can embed code like this:
1 + 1
2
You can add options to executable code like this
4
The echo: false
option disables the printing of code (only output is displayed).
import numpy as np
import matplotlib.pyplot as plt
= np.arange(0, 2, 0.01)
r = 2 * np.pi * r
theta = plt.subplots(subplot_kw={'projection': 'polar'})
fig, ax
ax.plot(theta, r)0.5, 1, 1.5, 2])
ax.set_rticks([True)
ax.grid( plt.show()
This document uses Font Awesome .
flowchart LR A[qmd] --> B(Knitr) A[qmd] --> C(Jupyter) B(Knitr) --> D[md] C(Jupyter) --> D[md] D[md] --> E(pandoc) E(pandoc) --> F(HTML) E(pandoc) --> G(PDF) E(pandoc) --> H(Word) E(pandoc) --> I{and more}
import spacy
= spacy.load("en_core_web_sm") nlp
='Tony Stark owns the company StarkEnterprises . Emily Clark works at Microsoft and lives in Manchester. She loves to read the Bible and learn French'
text=nlp(text) doc
print(doc.ents)
(Tony Stark, Clark, Microsoft, Bible, French)
for entity in doc.ents:
print(entity.text,'--- ',entity.label_)
Tony Stark --- PERSON
Clark --- PERSON
Microsoft --- ORG
Bible --- WORK_OF_ART
French --- LANGUAGE
from spacy import displacy
='ent',jupyter=True) displacy.render(doc,style