dt:10
opts_chunk$set(cache = F)
--- .YAML &masthead
title: Slidify menu: - {item: Home, href: "#", class: active} - {item: About, href: "about.html"}
- Thing 1
- Point 1
Point 2
Thing 2
- Point 3
- Point 4
--- {class: class, tpl: tabs}
This is to test if the tab template works correctly
*** {class: active, id: problem}
Tab1
*** {id: questions}
Tab2
*** {id: variables}
Tab3
This slide shows a Setext style header.
Mardown tables contain ---
and should not be interpreted as separator.
Column X | Column Y ---------|---------- Row 1 | Row 1 Row 2 | Row 2
--- bg:#662c91
This list should be animated
- Point 1
- Point 2
- Point 3
This list should be animated
- Point 1
- Point 2
- Point 3
$$
\begin{aligned}
\nabla \times \vec{\mathbf{B}} -\, \frac1c\, \frac{\partial\vec{\mathbf{E}}}{\partial t} & = \frac{4\pi}{c}\vec{\mathbf{j}} \ \nabla \cdot \vec{\mathbf{E}} & = 4 \pi \rho \
\nabla \times \vec{\mathbf{E}}\, +\, \frac1c\, \frac{\partial\vec{\mathbf{B}}}{\partial t} & = \vec{\mathbf{0}} \
\nabla \cdot \vec{\mathbf{B}} & = 0 \end{aligned}
$$
$$
\mathbf{V}_1 \times \mathbf{V}_2 = \begin{vmatrix}
\mathbf{i} & \mathbf{j} & \mathbf{k} \
\frac{\partial X}{\partial u} & \frac{\partial Y}{\partial u} & 0 \
\frac{\partial X}{\partial v} & \frac{\partial Y}{\partial v} & 0
\end{vmatrix}
$$
--- &twocol
This is a slide with a two column layout.
*** =left
Column 1
*** =right
Column 2
--- bg:#EEE
This slide should have a subtle gray background.
This slide should have a background image.
--- &radio
This is a multiple choice question
Choice 2
*** .hint
This is a hint
*** .explanation
This is the explanation
Blocks
This is an alert info block which should render in blue
Tooltips
This is to check out tooltips in bootstrap you probably
Popover
*** =pnotes
The font size and color needs some tweaking.
We can make this function more robust by adding a simple error checking statement to prevent illegal parameters from generating invalid results.
qpareto <- function(p, scale, loc) { if (( scale <= 0) | ( loc <= 0)) { stop("'qpareto' parameters must be greater than zero.") } q <- loc*(1 - p)^(-1/scale) return(q) }
Entering a negative parameter now raises an exception, instead of an invalid result that could silently corrupt subsequent results.
qpareto(0.4, 5, -1)
We could improve this further by checking to ensure that p
is a valid probability.
library(ggplot2); library(ggthemes); qplot(wt, mpg, data = mtcars) + theme_solarized()
*** =pnotes
This is a shout
I am checking key, key
--- #myslide
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.