library(ggplot2)
ggplot(airquality, aes(Temp, Ozone)) +
geom_point() +
geom_smooth(method = "loess"
)
Appendix C — Test Quarto Stuff 2
Also this here. And that here. And also here.
This. And that.
This is a book created from markdown and executable code.
See (JungTran2012JDE?) for additional discussion of literate programming.
fruit | price |
---|---|
apple | 2.05 |
pear | 1.37 |
orange | 3.09 |
C.1 Air Quality with R code
Figure fig-airquality further explores the impact of temperature on ozone level.
C.2 Python Code
1 + 1
2
Markdown allows you to write using an easy-to-read, easy-to-write plain text format.
And then we add some more.
Note that there are five types of callouts, including: note
, tip
, warning
, caution
, and important
.
This is an example of a callout with a caption.
C.3 Math Stuff Code
We know from the first fundamental theorem of calculus that for \(x\) in \([a, b]\):
\[\frac{d}{dx}\left( \int_{a}^{x} f(u)\,du\right)=f(x).\]
For a demonstration of a line plot on a polar axis, see Figure fig-polar.
library(ggplot2)
ggplot(airquality, aes(Temp, Ozone)) +
geom_point() +
geom_smooth(method = "loess"
)
#| label: fig-parametric
#| fig-cap: "Parametric Plots"
using Plots
plot(sin,
x->sin(2x),
0,
2π,
leg=false,
fill=(0,:lavender))
import numpy as np
import matplotlib.pyplot as plt
= np.arange(0, 2, 0.01)
r = 2 * np.pi * r
theta = plt.subplots(
fig, ax = {'projection': 'polar'}
subplot_kw
)
ax.plot(theta, r)0.5, 1, 1.5, 2])
ax.set_rticks([True)
ax.grid( plt.show()
If this is really a new file then just do it.