Skip to content

Commit

Permalink
Merge pull request DataScienceSpecialization#30 from bcaffo/master
Browse files Browse the repository at this point in the history
Added some shiny stuff
  • Loading branch information
jtleek committed May 8, 2014
2 parents 07e7f7e + addb360 commit bbf8368
Show file tree
Hide file tree
Showing 17 changed files with 7,445 additions and 7,526 deletions.
316 changes: 158 additions & 158 deletions 09_DevelopingDataProducts/manipulate/index.html
Original file line number Diff line number Diff line change
@@ -1,159 +1,159 @@
<!DOCTYPE html>
<html>
<head>
<title>Manipulate</title>
<meta charset="utf-8">
<meta name="description" content="Manipulate">
<meta name="author" content="Brian Caffo, Jeff Leek, Roger Peng">
<meta name="generator" content="slidify" />
<meta name="apple-mobile-web-app-capable" content="yes">
<meta http-equiv="X-UA-Compatible" content="chrome=1">
<link rel="stylesheet" href="../../librariesNew/frameworks/io2012/css/default.css" media="all" >
<link rel="stylesheet" href="../../librariesNew/frameworks/io2012/css/phone.css"
media="only screen and (max-device-width: 480px)" >
<link rel="stylesheet" href="../../librariesNew/frameworks/io2012/css/slidify.css" >
<link rel="stylesheet" href="../../librariesNew/highlighters/highlight.js/css/tomorrow.css" />
<base target="_blank"> <!-- This amazingness opens all links in a new tab. -->

<!-- Grab CDN jQuery, fall back to local if offline -->
<script src="http://ajax.aspnetcdn.com/ajax/jQuery/jquery-1.7.min.js"></script>
<script>window.jQuery || document.write('<script src="../../librariesNew/widgets/quiz/js/jquery.js"><\/script>')</script>
<script data-main="../../librariesNew/frameworks/io2012/js/slides"
src="../../librariesNew/frameworks/io2012/js/require-1.0.8.min.js">
</script>



</head>
<body style="opacity: 0">
<slides class="layout-widescreen">

<!-- LOGO SLIDE -->
<slide class="title-slide segue nobackground">
<aside class="gdbar">
<img src="../../assets/img/bloomberg_shield.png">
</aside>
<hgroup class="auto-fadein">
<h1>Manipulate</h1>
<h2>Data Products</h2>
<p>Brian Caffo, Jeff Leek, Roger Peng<br/>Johns Hopkins Bloomberg School of Public Health</p>
</hgroup>
<article></article>
</slide>


<!-- SLIDES -->
<slide class="" id="slide-1" style="background:;">
<hgroup>
<h2>Manipulate</h2>
</hgroup>
<article data-timings="">
<ul>
<li>Suppose that you want to create a quick interactive graphic

<ul>
<li>You have to do it <em>now</em> </li>
<li>The intended users also use Rstudio</li>
</ul></li>
<li><code>manipulate</code> is a really cool solution that is often all you need to quickly make interactive graphics</li>
</ul>

</article>
<!-- Presenter Notes -->
</slide>

<slide class="" id="slide-2" style="background:;">
<hgroup>
<h2>Documentation</h2>
</hgroup>
<article data-timings="">
<ul>
<li>Manipulate is well documented at the Rstudio web site here

<ul>
<li><a href="http://www.rstudio.com/ide/docs/advanced/manipulate">http://www.rstudio.com/ide/docs/advanced/manipulate</a></li>
</ul></li>
<li>From there, try this
<code>
library(manipulate)
manipulate(plot(1:x), x = slider(1, 100))
</code></li>
<li>You can create a slider, checkbox, or picker (drop down) and have more than one</li>
</ul>

</article>
<!-- Presenter Notes -->
</slide>

<slide class="" id="slide-3" style="background:;">
<hgroup>
<h2>Example from the regression class</h2>
</hgroup>
<article data-timings="">
<pre><code>library(manipulate)
myHist &lt;- function(mu){
hist(galton$child,col=&quot;blue&quot;,breaks=100)
lines(c(mu, mu), c(0, 150),col=&quot;red&quot;,lwd=5)
mse &lt;- mean((galton$child - mu)^2)
text(63, 150, paste(&quot;mu = &quot;, mu))
text(63, 140, paste(&quot;MSE = &quot;, round(mse, 2)))
}
manipulate(myHist(mu), mu = slider(62, 74, step = 0.5))
</code></pre>

</article>
<!-- Presenter Notes -->
</slide>

<slide class="backdrop"></slide>
</slides>
<div class="pagination pagination-small" id='io2012-ptoc' style="display:none;">
<ul>
<li>
<a href="#" target="_self" rel='tooltip'
data-slide=1 title='Manipulate'>
1
</a>
</li>
<li>
<a href="#" target="_self" rel='tooltip'
data-slide=2 title='Documentation'>
2
</a>
</li>
<li>
<a href="#" target="_self" rel='tooltip'
data-slide=3 title='Example from the regression class'>
3
</a>
</li>
</ul>
</div> <!--[if IE]>
<script
src="http://ajax.googleapis.com/ajax/libs/chrome-frame/1/CFInstall.min.js">
</script>
<script>CFInstall.check({mode: 'overlay'});</script>
<![endif]-->
</body>
<!-- Load Javascripts for Widgets -->

<!-- MathJax: Fall back to local if CDN offline but local image fonts are not supported (saves >100MB) -->
<script type="text/x-mathjax-config">
MathJax.Hub.Config({
tex2jax: {
inlineMath: [['$','$'], ['\\(','\\)']],
processEscapes: true
}
});
</script>
<script type="text/javascript" src="http://cdn.mathjax.org/mathjax/2.0-latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML"></script>
<!-- <script src="https://c328740.ssl.cf1.rackcdn.com/mathjax/2.0-latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML">
</script> -->
<script>window.MathJax || document.write('<script type="text/x-mathjax-config">MathJax.Hub.Config({"HTML-CSS":{imageFont:null}});<\/script><script src="../../librariesNew/widgets/mathjax/MathJax.js?config=TeX-AMS-MML_HTMLorMML"><\/script>')
</script>
<!-- LOAD HIGHLIGHTER JS FILES -->
<script src="../../librariesNew/highlighters/highlight.js/highlight.pack.js"></script>
<script>hljs.initHighlightingOnLoad();</script>
<!-- DONE LOADING HIGHLIGHTER JS FILES -->

<!DOCTYPE html>
<html>
<head>
<title>Manipulate</title>
<meta charset="utf-8">
<meta name="description" content="Manipulate">
<meta name="author" content="Brian Caffo, Jeff Leek, Roger Peng">
<meta name="generator" content="slidify" />
<meta name="apple-mobile-web-app-capable" content="yes">
<meta http-equiv="X-UA-Compatible" content="chrome=1">
<link rel="stylesheet" href="../../librariesNew/frameworks/io2012/css/default.css" media="all" >
<link rel="stylesheet" href="../../librariesNew/frameworks/io2012/css/phone.css"
media="only screen and (max-device-width: 480px)" >
<link rel="stylesheet" href="../../librariesNew/frameworks/io2012/css/slidify.css" >
<link rel="stylesheet" href="../../librariesNew/highlighters/highlight.js/css/tomorrow.css" />
<base target="_blank"> <!-- This amazingness opens all links in a new tab. -->

<!-- Grab CDN jQuery, fall back to local if offline -->
<script src="http://ajax.aspnetcdn.com/ajax/jQuery/jquery-1.7.min.js"></script>
<script>window.jQuery || document.write('<script src="../../librariesNew/widgets/quiz/js/jquery.js"><\/script>')</script>
<script data-main="../../librariesNew/frameworks/io2012/js/slides"
src="../../librariesNew/frameworks/io2012/js/require-1.0.8.min.js">
</script>



</head>
<body style="opacity: 0">
<slides class="layout-widescreen">

<!-- LOGO SLIDE -->
<slide class="title-slide segue nobackground">
<aside class="gdbar">
<img src="../../assets/img/bloomberg_shield.png">
</aside>
<hgroup class="auto-fadein">
<h1>Manipulate</h1>
<h2>Data Products</h2>
<p>Brian Caffo, Jeff Leek, Roger Peng<br/>Johns Hopkins Bloomberg School of Public Health</p>
</hgroup>
<article></article>
</slide>


<!-- SLIDES -->
<slide class="" id="slide-1" style="background:;">
<hgroup>
<h2>Manipulate</h2>
</hgroup>
<article data-timings="">
<ul>
<li>Suppose that you want to create a quick interactive graphic

<ul>
<li>You have to do it <em>now</em> </li>
<li>The intended users also use Rstudio</li>
</ul></li>
<li><code>manipulate</code> is a really cool solution that is often all you need to quickly make interactive graphics</li>
</ul>

</article>
<!-- Presenter Notes -->
</slide>

<slide class="" id="slide-2" style="background:;">
<hgroup>
<h2>Documentation</h2>
</hgroup>
<article data-timings="">
<ul>
<li>Manipulate is well documented at the Rstudio web site here

<ul>
<li><a href="http://www.rstudio.com/ide/docs/advanced/manipulate">http://www.rstudio.com/ide/docs/advanced/manipulate</a></li>
</ul></li>
<li>From there, try this
<code>
library(manipulate)
manipulate(plot(1:x), x = slider(1, 100))
</code></li>
<li>You can create a slider, checkbox, or picker (drop down) and have more than one</li>
</ul>

</article>
<!-- Presenter Notes -->
</slide>

<slide class="" id="slide-3" style="background:;">
<hgroup>
<h2>Example from the regression class</h2>
</hgroup>
<article data-timings="">
<pre><code>library(manipulate)
myHist &lt;- function(mu){
hist(galton$child,col=&quot;blue&quot;,breaks=100)
lines(c(mu, mu), c(0, 150),col=&quot;red&quot;,lwd=5)
mse &lt;- mean((galton$child - mu)^2)
text(63, 150, paste(&quot;mu = &quot;, mu))
text(63, 140, paste(&quot;MSE = &quot;, round(mse, 2)))
}
manipulate(myHist(mu), mu = slider(62, 74, step = 0.5))
</code></pre>

</article>
<!-- Presenter Notes -->
</slide>

<slide class="backdrop"></slide>
</slides>
<div class="pagination pagination-small" id='io2012-ptoc' style="display:none;">
<ul>
<li>
<a href="#" target="_self" rel='tooltip'
data-slide=1 title='Manipulate'>
1
</a>
</li>
<li>
<a href="#" target="_self" rel='tooltip'
data-slide=2 title='Documentation'>
2
</a>
</li>
<li>
<a href="#" target="_self" rel='tooltip'
data-slide=3 title='Example from the regression class'>
3
</a>
</li>
</ul>
</div> <!--[if IE]>
<script
src="http://ajax.googleapis.com/ajax/libs/chrome-frame/1/CFInstall.min.js">
</script>
<script>CFInstall.check({mode: 'overlay'});</script>
<![endif]-->
</body>
<!-- Load Javascripts for Widgets -->

<!-- MathJax: Fall back to local if CDN offline but local image fonts are not supported (saves >100MB) -->
<script type="text/x-mathjax-config">
MathJax.Hub.Config({
tex2jax: {
inlineMath: [['$','$'], ['\\(','\\)']],
processEscapes: true
}
});
</script>
<script type="text/javascript" src="http://cdn.mathjax.org/mathjax/2.0-latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML"></script>
<!-- <script src="https://c328740.ssl.cf1.rackcdn.com/mathjax/2.0-latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML">
</script> -->
<script>window.MathJax || document.write('<script type="text/x-mathjax-config">MathJax.Hub.Config({"HTML-CSS":{imageFont:null}});<\/script><script src="../../librariesNew/widgets/mathjax/MathJax.js?config=TeX-AMS-MML_HTMLorMML"><\/script>')
</script>
<!-- LOAD HIGHLIGHTER JS FILES -->
<script src="../../librariesNew/highlighters/highlight.js/highlight.pack.js"></script>
<script>hljs.initHighlightingOnLoad();</script>
<!-- DONE LOADING HIGHLIGHTER JS FILES -->

</html>
Loading

0 comments on commit bbf8368

Please sign in to comment.