-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #3 from dbkegley/add-content
Add new content items
- Loading branch information
Showing
38 changed files
with
8,087 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
{ | ||
"cells": [ | ||
{ | ||
"cell_type": "code", | ||
"execution_count": null, | ||
"metadata": {}, | ||
"outputs": [], | ||
"source": [ | ||
"123 + 456" | ||
] | ||
} | ||
], | ||
"metadata": { | ||
"kernelspec": { | ||
"display_name": "Python 3", | ||
"language": "python", | ||
"name": "python3" | ||
}, | ||
"language_info": { | ||
"codemirror_mode": { | ||
"name": "ipython", | ||
"version": 3 | ||
}, | ||
"file_extension": ".py", | ||
"mimetype": "text/x-python", | ||
"name": "python", | ||
"nbconvert_exporter": "python", | ||
"pygments_lexer": "ipython3", | ||
"version": "3.7.0" | ||
}, | ||
"rsconnect": { | ||
"previousServerId": null, | ||
"servers": { | ||
"77e78af2-656c-4bd1-a8ac-9e9e02f13208": { | ||
"server": "http://192.168.0.111:3939/", | ||
"serverName": "local" | ||
} | ||
} | ||
} | ||
}, | ||
"nbformat": 4, | ||
"nbformat_minor": 2 | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
{ | ||
"locale": "en_US.UTF-8", | ||
"python": { | ||
"version": "3.8.12", | ||
"package_manager": { | ||
"name": "pip", | ||
"version": "22.2.2", | ||
"package_file": "requirements.txt" | ||
} | ||
}, | ||
"version": 1, | ||
"files": { | ||
"add.ipynb": { | ||
"checksum": "085e17945a26a2c04996861914e1e457" | ||
}, | ||
"requirements.txt": { | ||
"checksum": "b1b2cc61ee57e86353113c217c6ea26c" | ||
} | ||
}, | ||
"metadata": { | ||
"appmode": "jupyter-static", | ||
"entrypoint": "add.ipynb" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
attrs==19.3.0 | ||
backcall==0.2.0 | ||
bleach==3.1.5 | ||
decorator==4.4.2 | ||
defusedxml==0.6.0 | ||
entrypoints==0.3 | ||
ipykernel==5.3.2 | ||
ipython==7.16.1 | ||
ipython-genutils==0.2.0 | ||
ipywidgets==7.5.1 | ||
jedi==0.17.1 | ||
Jinja2==2.11.2 | ||
jsonschema==3.2.0 | ||
jupyter==1.0.0 | ||
jupyter-client==6.1.6 | ||
jupyter-console==6.1.0 | ||
jupyter-core==4.6.3 | ||
MarkupSafe==1.1.1 | ||
mistune==0.8.4 | ||
nbconvert==5.6.1 | ||
nbformat==5.0.7 | ||
notebook==6.0.3 | ||
packaging==20.4 | ||
pandocfilters==1.4.2 | ||
parso==0.7.0 | ||
pexpect==4.8.0 | ||
pickleshare==0.7.5 | ||
prometheus-client==0.8.0 | ||
prompt-toolkit==3.0.5 | ||
ptyprocess==0.6.0 | ||
Pygments==2.6.1 | ||
pyparsing==2.4.7 | ||
pyrsistent==0.16.0 | ||
python-dateutil==2.8.1 | ||
pyzmq==19.0.1 | ||
qtconsole==4.7.5 | ||
QtPy==1.9.0 | ||
Send2Trash==1.5.0 | ||
six==1.15.0 | ||
terminado==0.8.3 | ||
testpath==0.4.4 | ||
tornado==6.0.4 | ||
traitlets==4.3.3 | ||
wcwidth==0.2.5 | ||
webencodings==0.5.1 | ||
widgetsnbextension==3.5.1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
/.quarto/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
project: | ||
title: "shiny" | ||
|
||
|
||
|
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,203 @@ | ||
<!DOCTYPE html> | ||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"><head> | ||
|
||
<meta charset="utf-8"> | ||
<meta name="generator" content="quarto-0.9.649"> | ||
|
||
<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes"> | ||
|
||
|
||
<title>Old Faithful</title> | ||
<style> | ||
code{white-space: pre-wrap;} | ||
span.smallcaps{font-variant: small-caps;} | ||
span.underline{text-decoration: underline;} | ||
div.column{display: inline-block; vertical-align: top; width: 50%;} | ||
div.hanging-indent{margin-left: 1.5em; text-indent: -1.5em;} | ||
ul.task-list{list-style: none;} | ||
</style> | ||
|
||
|
||
<script src="shiny_files/libs/clipboard/clipboard.min.js"></script> | ||
<script src="shiny_files/libs/quarto-html/quarto.js"></script> | ||
<script src="shiny_files/libs/quarto-html/popper.min.js"></script> | ||
<script src="shiny_files/libs/quarto-html/tippy.umd.min.js"></script> | ||
<script src="shiny_files/libs/quarto-html/anchor.min.js"></script> | ||
<link href="shiny_files/libs/quarto-html/tippy.css" rel="stylesheet"> | ||
<link href="shiny_files/libs/quarto-html/quarto-syntax-highlighting.css" rel="stylesheet" id="quarto-text-highlighting-styles"> | ||
<script src="shiny_files/libs/bootstrap/bootstrap.min.js"></script> | ||
<link href="shiny_files/libs/bootstrap/bootstrap-icons.css" rel="stylesheet"> | ||
<link href="shiny_files/libs/bootstrap/bootstrap.min.css" rel="stylesheet"> | ||
|
||
|
||
</head> | ||
|
||
<body class="fullcontent"> | ||
|
||
<div id="quarto-content" class="page-columns page-rows-contents page-layout-article"> | ||
|
||
<main class="content" id="quarto-document-content"> | ||
|
||
<header id="title-block-header" class="quarto-title-block default"> | ||
<div class="quarto-title"> | ||
<h1 class="title">Old Faithful</h1> | ||
</div> | ||
|
||
|
||
|
||
<div class="quarto-title-meta"> | ||
|
||
|
||
|
||
</div> | ||
|
||
|
||
</header> | ||
|
||
<div class="cell"> | ||
<div class="cell-output-display"> | ||
<div class="form-group shiny-input-container"> | ||
<label class="control-label" id="bins-label" for="bins">Number of bins:</label> | ||
<input class="js-range-slider" id="bins" data-skin="shiny" data-min="1" data-max="50" data-from="30" data-step="1" data-grid="true" data-grid-num="9.8" data-grid-snap="false" data-prettify-separator="," data-prettify-enabled="true" data-keyboard="true" data-data-type="number"> | ||
</div> | ||
</div> | ||
<div class="cell-output-display"> | ||
<p></p><div id="distPlot" class="shiny-plot-output" style="width:100%;height:400px;"></div><p></p> | ||
</div> | ||
</div> | ||
<div class="cell" data-context="server"> | ||
|
||
</div> | ||
|
||
<script type="application/shiny-prerendered" data-context="server"> | ||
output$distPlot <- renderPlot({ | ||
x <- faithful[, 2] # Old Faithful Geyser data | ||
bins <- seq(min(x), max(x), length.out = input$bins + 1) | ||
hist(x, breaks = bins, col = 'darkgray', border = 'white') | ||
}) | ||
</script> | ||
|
||
<script type="application/shiny-prerendered" data-context="server-extras"> | ||
ojs_define <- function(..., .session = shiny::getDefaultReactiveDomain()) { | ||
quos <- rlang::enquos(...) | ||
vars <- rlang::list2(...) | ||
nm <- names(vars) | ||
if (is.null(nm)) { | ||
nm <- rep_len("", length(vars)) | ||
} | ||
mapply(function(q, nm, val) { | ||
# Infer name, if possible | ||
if (nm == "") { | ||
tryCatch({ | ||
nm <- rlang::as_name(q) | ||
}, error = function(e) { | ||
code <- paste(collapse = "\n", deparse(rlang::f_rhs(q))) | ||
stop("ojs_define() could not create a name for the argument: ", code) | ||
}) | ||
} | ||
.session$output[[nm]] <- val | ||
outputOptions(.session$output, nm, suspendWhenHidden = FALSE) | ||
.session$sendCustomMessage("ojs-export", list(name = nm)) | ||
NULL | ||
}, quos, nm, vars, SIMPLIFY = FALSE, USE.NAMES = FALSE) | ||
invisible() | ||
} | ||
</script> | ||
<!--html_preserve--> | ||
<script type="application/shiny-prerendered" data-context="dependencies"> | ||
{"type":"list","attributes":{},"value":[{"type":"list","attributes":{"names":{"type":"character","attributes":{},"value":["name","version","src","meta","script","stylesheet","head","attachment","package","all_files"]},"class":{"type":"character","attributes":{},"value":["html_dependency"]}},"value":[{"type":"character","attributes":{},"value":["ionrangeslider-javascript"]},{"type":"character","attributes":{},"value":["2.3.1"]},{"type":"list","attributes":{"names":{"type":"character","attributes":{},"value":["href"]}},"value":[{"type":"character","attributes":{},"value":["shared/ionrangeslider"]}]},{"type":"NULL"},{"type":"character","attributes":{},"value":["js/ion.rangeSlider.min.js"]},{"type":"NULL"},{"type":"NULL"},{"type":"NULL"},{"type":"NULL"},{"type":"logical","attributes":{},"value":[true]}]},{"type":"list","attributes":{"names":{"type":"character","attributes":{},"value":["name","version","src","meta","script","stylesheet","head","attachment","package","all_files"]},"class":{"type":"character","attributes":{},"value":["html_dependency"]}},"value":[{"type":"character","attributes":{},"value":["strftime"]},{"type":"character","attributes":{},"value":["0.9.2"]},{"type":"list","attributes":{"names":{"type":"character","attributes":{},"value":["href"]}},"value":[{"type":"character","attributes":{},"value":["shared/strftime"]}]},{"type":"NULL"},{"type":"character","attributes":{},"value":["strftime-min.js"]},{"type":"NULL"},{"type":"NULL"},{"type":"NULL"},{"type":"NULL"},{"type":"logical","attributes":{},"value":[true]}]},{"type":"list","attributes":{"names":{"type":"character","attributes":{},"value":["name","version","src","meta","script","stylesheet","head","attachment","package","all_files"]},"class":{"type":"character","attributes":{},"value":["html_dependency"]}},"value":[{"type":"character","attributes":{},"value":["ionrangeslider-css"]},{"type":"character","attributes":{},"value":["2.3.1"]},{"type":"list","attributes":{"names":{"type":"character","attributes":{},"value":["href"]}},"value":[{"type":"character","attributes":{},"value":["shared/ionrangeslider"]}]},{"type":"NULL"},{"type":"NULL"},{"type":"character","attributes":{},"value":["css/ion.rangeSlider.css"]},{"type":"NULL"},{"type":"NULL"},{"type":"NULL"},{"type":"logical","attributes":{},"value":[true]}]}]} | ||
</script> | ||
<!--/html_preserve--> | ||
<!--html_preserve--> | ||
|
||
<script type="application/shiny-prerendered" data-context="execution_dependencies"> | ||
{"type":"list","attributes":{"names":{"type":"character","attributes":{},"value":["packages"]}},"value":[{"type":"list","attributes":{"names":{"type":"character","attributes":{},"value":["packages","version"]},"class":{"type":"character","attributes":{},"value":["data.frame"]},"row.names":{"type":"integer","attributes":{},"value":[1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36]}},"value":[{"type":"character","attributes":{},"value":["base","bslib","compiler","datasets","digest","ellipsis","evaluate","fastmap","graphics","grDevices","htmltools","htmlwidgets","httpuv","jquerylib","jsonlite","knitr","later","lifecycle","magrittr","methods","mime","promises","R6","Rcpp","rlang","rmarkdown","sass","shiny","stats","stringi","stringr","tools","utils","xfun","xtable","yaml"]},{"type":"character","attributes":{},"value":["4.1.2","0.3.1","4.1.2","4.1.2","0.6.29","0.3.2","0.14","1.1.0","4.1.2","4.1.2","0.5.2","1.5.4","1.6.5","0.1.4","1.8.0","1.37","1.3.0","1.0.1","2.0.1","4.1.2","0.12","1.2.0.1","2.5.1","1.0.7","0.4.12","2.11","0.4.0","1.7.1","4.1.2","1.7.6","1.4.0","4.1.2","4.1.2","0.29","1.8-4","2.3.5"]}]}]} | ||
</script> | ||
<!--/html_preserve--> | ||
|
||
</main> | ||
<!-- /main column --> | ||
<script id="quarto-html-after-body" type="application/javascript"> | ||
window.document.addEventListener("DOMContentLoaded", function (event) { | ||
const icon = ""; | ||
const anchorJS = new window.AnchorJS(); | ||
anchorJS.options = { | ||
placement: 'right', | ||
icon: icon | ||
}; | ||
anchorJS.add('.anchored'); | ||
const clipboard = new window.ClipboardJS('.code-copy-button', { | ||
target: function(trigger) { | ||
return trigger.previousElementSibling; | ||
} | ||
}); | ||
clipboard.on('success', function(e) { | ||
// button target | ||
const button = e.trigger; | ||
// don't keep focus | ||
button.blur(); | ||
// flash "checked" | ||
button.classList.add('code-copy-button-checked'); | ||
var currentTitle = button.getAttribute("title"); | ||
button.setAttribute("title", "Copied!"); | ||
setTimeout(function() { | ||
button.setAttribute("title", currentTitle); | ||
button.classList.remove('code-copy-button-checked'); | ||
}, 1000); | ||
// clear code selection | ||
e.clearSelection(); | ||
}); | ||
function tippyHover(el, contentFn) { | ||
const config = { | ||
allowHTML: true, | ||
content: contentFn, | ||
maxWidth: 500, | ||
delay: 100, | ||
arrow: false, | ||
appendTo: function(el) { | ||
return el.parentElement; | ||
}, | ||
interactive: true, | ||
interactiveBorder: 10, | ||
theme: 'quarto', | ||
placement: 'bottom-start' | ||
}; | ||
window.tippy(el, config); | ||
} | ||
const noterefs = window.document.querySelectorAll('a[role="doc-noteref"]'); | ||
for (var i=0; i<noterefs.length; i++) { | ||
const ref = noterefs[i]; | ||
tippyHover(ref, function() { | ||
let href = ref.getAttribute('href'); | ||
try { href = new URL(href).hash; } catch {} | ||
const id = href.replace(/^#\/?/, ""); | ||
const note = window.document.getElementById(id); | ||
return note.innerHTML; | ||
}); | ||
} | ||
var bibliorefs = window.document.querySelectorAll('a[role="doc-biblioref"]'); | ||
for (var i=0; i<bibliorefs.length; i++) { | ||
const ref = bibliorefs[i]; | ||
const cites = ref.parentNode.getAttribute('data-cites').split(' '); | ||
tippyHover(ref, function() { | ||
var popup = window.document.createElement('div'); | ||
cites.forEach(function(cite) { | ||
var citeDiv = window.document.createElement('div'); | ||
citeDiv.classList.add('hanging-indent'); | ||
citeDiv.classList.add('csl-entry'); | ||
var biblioDiv = window.document.getElementById('ref-' + cite); | ||
if (biblioDiv) { | ||
citeDiv.innerHTML = biblioDiv.innerHTML; | ||
} | ||
popup.appendChild(citeDiv); | ||
}); | ||
return popup.innerHTML; | ||
}); | ||
} | ||
}); | ||
</script> | ||
</div> <!-- /content --> | ||
|
||
|
||
|
||
</body></html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
--- | ||
title: "Old Faithful" | ||
format: html | ||
server: shiny | ||
--- | ||
|
||
```{r} | ||
sliderInput("bins", "Number of bins:", | ||
min = 1, max = 50, value = 30) | ||
plotOutput("distPlot") | ||
``` | ||
|
||
```{r} | ||
#| context: server | ||
output$distPlot <- renderPlot({ | ||
x <- faithful[, 2] # Old Faithful Geyser data | ||
bins <- seq(min(x), max(x), length.out = input$bins + 1) | ||
hist(x, breaks = bins, col = 'darkgray', border = 'white') | ||
}) | ||
``` |
Oops, something went wrong.