Skip to content

Commit

Permalink
Merge pull request #9 from apreshill/fix-htmlwidgets
Browse files Browse the repository at this point in the history
Fix htmlwidgets
  • Loading branch information
dcossyleon authored Sep 4, 2019
2 parents 1546017 + c5fc0e3 commit 4f0009e
Show file tree
Hide file tree
Showing 13 changed files with 242 additions and 173 deletions.
30 changes: 30 additions & 0 deletions archetypes/post/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
---
# Documentation: https://sourcethemes.com/academic/docs/managing-content/

title: "{{ replace .Name "-" " " | title }}"
subtitle: ""
summary: ""
authors: []
tags: []
categories: []
date: {{ .Date }}
lastmod: {{ .Date }}
featured: false
draft: false
disable_jquery: false

# Featured image
# To use, add an image named `featured.jpg/png` to your page's folder.
# Focal points: Smart, Center, TopLeft, Top, TopRight, Left, Right, BottomLeft, Bottom, BottomRight.
image:
caption: ""
focal_point: ""
preview_only: false

# Projects (optional).
# Associate this post with one or more of your projects.
# Simply enter your project's folder or file name without extension.
# E.g. `projects = ["internal-project"]` references `content/project/deep-learning/index.md`.
# Otherwise, set `projects = []`.
projects: []
---
2 changes: 1 addition & 1 deletion content/post/2019-06-13-trying-out-blogdown/index.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ image:
focal_point: ''
preview_only: no
projects: []
disable_jquery: true # for htmlwidgets
---

# Hello!
Expand Down Expand Up @@ -108,4 +109,3 @@ datatable(behavior)

<br>

Hmm...blogdown leaves me with yet another mystery. The datatable renders just fine within the RStudio IDE, but not when the site renders. How can this be?
12 changes: 4 additions & 8 deletions content/post/2019-06-13-trying-out-blogdown/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
focal_point: ''
preview_only: no
projects: []
disable_jquery: true # for htmlwidgets
---

<script src="/rmarkdown-libs/htmlwidgets/htmlwidgets.js"></script>
Expand Down Expand Up @@ -44,13 +45,9 @@ <h1>Hello!</h1>
<div id="iris-data-set" class="section level1">
<h1>1) Iris data set</h1>
<p>Let’s make a plot using the <code>iris</code> data set in <code>ggplot2</code>.</p>
<pre class="r"><code>library(ggplot2)</code></pre>
<pre><code>## Registered S3 methods overwritten by &#39;ggplot2&#39;:
## method from
## [.quosures rlang
## c.quosures rlang
## print.quosures rlang</code></pre>
<pre class="r"><code># Dataset
<pre class="r"><code>library(ggplot2)

# Dataset
head(iris)</code></pre>
<pre><code>## Sepal.Length Sepal.Width Petal.Length Petal.Width Species
## 1 5.1 3.5 1.4 0.2 setosa
Expand Down Expand Up @@ -129,5 +126,4 @@ <h1>6) Reading in a data set</h1>
<div id="htmlwidget-1" style="width:100%;height:auto;" class="datatables html-widget"></div>
<script type="application/json" data-for="htmlwidget-1">{"x":{"filter":"none","data":[["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","37","38","39","40","41","42","43","44","45","46","47","48","49","50","51","52","53","54","55","56","57","58","59","60","61","62","63","64","65","66","67","68","69","70","71","72","73","74","75","76","77","78","79","80","81","82","83","84","85","86","87","88","89","90","91","92","93","94","95","96","97","98","99","100","101","102","103","104","105","106","107","108","109","110","111","112","113","114","115","116","117","118","119","120","121","122","123","124","125","126","127","128","129","130","131","132","133","134","135","136","137","138","139","140","141","142","143","144","145","146","147","148","149","150","151","152","153","154","155","156","157","158","159","160","161","162","163","164","165","166","167","168","169","170","171","172","173","174","175","176","177","178","179","180","181","182","183","184","185","186","187","188","189","190","191","192","193","194","195","196","197","198","199","200","201","202","203","204","205","206","207","208","209","210","211","212","213","214"],["bs9","gk3","se8","qq8","vd8","qv5","sr8","pk8","oz4","hv5","bp8","oz6","cs5","us8","gc8","sb9","mv5","km6","jb8","dq9","aj9","ph7","ku9","et6","ck7","wt9","oj7","jo7","te8","rq9","kj3","um1","fw6","hc6","rf5","kw6","mk7","wv8","sy9","ik3","nv8","le7","cm8","uj5","mh5","le9","go4","gj9","oi3","fl9","wc3","mm3","rc9","zz9","lb7","cb6","cj9","ru5","me6","fi9","pl8","on7","ti8","de8","sh1","rm7","as8","py8","np9","im8","ie6","ts3","tf6","ks3","vw9","uy8","vo8","au4","ga9","ha10","fc9","rb9","cq9","qd10","nw4","er9","kp7","cn8","lf8","sb7","pd10","tu9","qs7","be6","ob7","el7","wi3","up9","zp5","sl6","ms5","zc9","hc10","ea4","gz9","ad9","ue9","ay9","mp8","sa9","hd10","ve9","ka7","nu5","mj7","kv7","hg6","bf7","pc10","fp7","jm7","nw6","gs7","je9","wo7","tp9","zv9","rt9","oj3","fe9","zs7","mf3","wa10","lh5","df8","na9","ay8","tl5","ty4","hz5","ws8","kt9","vm7","da10","zw6","tf1","fn7","yq6","ak9","jp7","wm8","yf4","we9","er4","uf1","qd8","bc6","tc9","io9","dq3","vd10","qv7","kp9","kh7","oc10","mv8","ma9","qc4","nd7","ds3","oo9","tb8","qh7","ea6","ad8","pb7","nn7","ik6","ef6","wk4","vh9","ze10","ip6","ru3","ek6","bq6","jk9","gv5","yv8","fk9","hl8","ib8","zi6","fu5","mf10","te4","qn8","jw8","jb9","tj6","sd4","qp9","zm4","hm8","dh7","du5","qj4","dm4","zj6","jf8","wp9","hb9","uy5","yn8"],["a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","a1","bc1a","bc1a","bc1a","bc1a","bc1a","bc1a","bc1a","bc1a","bc1a","bc1a","bc1a","bc1a","bc1a","bc1a","bc1a","bc1a","bc1a","bc1a","bc1a","bc1a","bc1a","bc1a","bc1a","bc1a","bc1a","bc1a","bc1a","bc1a","bc1a","bc1a","bc1a","bc1a","bc1a","bc1a","bc1a","bc1a","bc1a","bc2b","bc2b","bc2b","bc2b","bc2b","bc2b","bc2b","bc2b","bc2b","bc2b","bc2b","bc2b","bc2b","bc2b","bc2b","bc2b","bc2b","bc2b","bc2b","bc2b","bc2b","bc2b","bc2b","bc2b","bc2b","bc2b","bc2b","bc2b","bc2b","bc2b","bc2b","bc2b","bc2b","bc2b","bc2b","bc2b","d1","d1","d1","d1","d1","d1","d1","d1","d1","d1","d1","d1","d1","d1","d1","d1","d1","d1","d1","d1","d1","d1","d1","d1","d1","d1","d1","d1","d1","d1","d1","d1","d1","d1","d1","d1","d2","d2","d2","d2","d2","d2","d2","d2","d2","d2","d2","d2","d2","d2","d2","d2","d2","d2","d2","d2","d2","d2"],[2003,1991,2001,2001,2001,1996,2001,2001,1994,1996,2001,1999,1996,2001,2001,2002,1996,1998,2001,2003,2002,1999,2003,1998,2000,2003,2000,2000,2001,2003,1991,1986,1999,1997,1995,1999,2000,2002,2003,1991,2002,1999,2001,1995,1995,2002,1993,2002,1991,2002,1990,1991,2002,2003,1999,1997,2002,1996,1997,2002,2001,2000,2001,2001,1985,2000,2001,2002,2003,2001,1997,1992,1997,1992,2003,2002,2001,1994,2002,2003,2002,2002,2003,2003,1994,2003,2000,2001,2001,1999,2003,2003,2000,1997,1999,2000,1991,2003,1996,1998,1996,2002,2003,1992,2003,2002,2002,2003,2001,2002,2003,2002,1999,1996,2000,2000,1997,1999,2003,2000,2000,1999,2000,2002,2000,2003,2003,2003,1991,2002,2000,1991,2003,1995,2001,2002,2002,1995,1994,1997,2001,2003,2000,2003,1999,1983,2000,1998,2002,2000,2001,1993,2002,1994,1983,2001,1997,2002,2003,1992,2003,2000,2003,1999,2003,2002,2002,1993,1999,1992,2003,2001,1999,1997,2001,1999,2000,1998,1997,1993,2002,2003,1998,1992,1998,1998,2002,1996,2002,2002,2001,2001,1998,1996,2003,1993,2001,2002,2002,1998,1993,2003,1993,2001,1999,1996,1993,1993,1998,2001,2003,2002,1997,2001],[2008,2007,2008,2008,2008,2008,2008,2008,2008,2007,2008,2008,2007,2008,2008,2008,2007,2007,2007,2008,2008,2008,2007,2007,2007,2008,2007,2008,2007,2008,2007,2007,2007,2007,2007,2007,2008,2007,2008,2008,2008,2007,2008,2008,2007,2008,2007,2008,2007,2008,2008,2008,2007,2008,2008,2007,2008,2007,2008,2008,2008,2008,2008,2007,2007,2008,2007,2007,2008,2008,2008,2007,2007,2008,2008,2007,2008,2008,2007,2008,2008,2008,2008,2008,2008,2008,2007,2008,2008,2007,2008,2008,2008,2007,2008,2007,2008,2008,2008,2007,2007,2008,2008,2008,2008,2008,2008,2008,2008,2008,2008,2008,2007,2007,2007,2008,2007,2008,2008,2008,2007,2007,2007,2009,2007,2009,2009,2009,2007,2009,2007,2007,2009,2007,2009,2009,2009,2007,2007,2007,2009,2009,2007,2009,2007,2007,2007,2007,2009,2007,2009,2007,2009,2007,2007,2009,2009,2008,2008,2008,2008,2008,2008,2008,2009,2008,2008,2008,2008,2008,2008,2008,2008,2008,2008,2008,2008,2008,2008,2008,2008,2008,2008,2008,2008,2009,2008,2009,2008,2008,2008,2008,2008,2008,2008,2009,2009,2009,2009,2008,2008,2009,2008,2009,2008,2009,2009,2008,2009,2009,2009,2009,2008,2009],[3,1,1,3,3,3,2,2,1,2,1,2,2,2,3,2,3,2,3,1,3,2,1,2,1,2,1,3,1,2,2,3,3,1,2,2,3,3,1,3,3,1,3,3,1,1,1,3,2,3,3,3,3,3,1,2,1,1,3,2,3,2,2,1,2,2,3,1,1,2,2,2,2,2,2,1,1,2,1,3,1,2,3,1,1,2,2,3,2,2,3,1,2,2,2,3,3,2,3,1,2,1,2,2,3,3,2,3,2,1,2,1,1,2,2,3,2,1,2,1,2,2,3,2,3,3,2,2,1,3,3,2,1,3,3,2,2,1,3,2,3,2,1,2,3,1,3,2,1,1,1,1,3,3,1,1,1,1,3,1,1,3,3,2,1,3,1,2,1,2,1,3,3,3,3,1,3,2,1,1,3,3,1,3,2,1,3,3,3,3,1,3,1,3,1,1,2,1,1,1,2,2,3,1,2,3,1,1,1,1,1,2,2,3],["N","Y","N","N","Y","Y","N","Y","N","N","N","Y","N","Y","N","N","Y","N","N","Y","Y","Y","Y","N","Y","Y","N","Y","Y","Y","Y","Y","Y","N","Y","Y","Y","Y","N","Y","N","N","Y","N","Y","N","Y","N","N","N","Y","Y","N","Y","Y","N","N","Y","Y","Y","Y","N","Y","N","N","Y","N","N","Y","Y","Y","Y","N","N","Y","Y","Y","N","N","N","Y","Y","N","N","Y","Y","N","Y","Y","N","N","Y","Y","N","N","N","N","Y","Y","N","Y","Y","Y","N","Y","N","N","N","N","Y","Y","Y","N","N","N","Y","N","Y","N","Y","Y","Y","Y","Y","Y","N","Y","Y","N","N","Y","Y","N","Y","N","Y","N","N","N","Y","N","N","Y","Y","Y","N","N","Y","Y","Y","Y","N","N","Y","N","Y","N","N","N","N","N","N","Y","N","Y","N","Y","N","Y","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","Y","N","N","N","N","N","N","N","N","N","Y","N","Y","Y","Y","N","Y","Y","N","Y","Y","N","Y","Y","Y","Y","Y","Y","N","N"],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0.748354,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0.737572,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0.741372,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0.741904,0,0,0,0,0,0,0.747198,0.745944,0,0,0,0,0,0,0.739235,0.743623,0,0,0,0,0,0,0,0.745684,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0.739454,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0.741895,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0.744611,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0.735583,0,0,0,0,0,0,0,0.748279,0,0,0,0,0,0,0,0,0,0,1.4888,0,0,0,0,0,0,0.748148,0,1.49592,0,0,0,0.748344,0,0,0.744094,0,2.2317,0,0,0.745101,0,0],[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0.747151,0,0.746269,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0.770753,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0.742988,0,0,0,0,0,0,0,0,0,0,0,0,0.747021,0,0,0.745944,0,0,0,0,0,0,2.2177,0,0,0,0,0,0,0,0,0,0,0,0.747589,0,0,0,1.49484,0,0,0,0,0,0,0,0,0.744648,1.4806,0,0.743329,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0.747841,2.98969,0,0,0,0,0,0,0,0,0.74897,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0.74096,0,0,0,0,0,0,0.748372,0.727264,0,0,0,0,0,0,0.741987,0,0,0,0,0,0,0,0.745823,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1.49592,0,0.74625,0,0,0,0,0,0,0,0,0,0.745101,0,0],[0,0,0,2.23206,0.997506,0,0,0,0,0,0,0,1.49802,0,0,0.747151,0,1.49254,0,0,0,0.737318,0,1.49207,0,0,1.48998,0,1.496,0,2.3233,0,0,0,0.742896,0,0,0.743292,0.998502,0,0,1.49674,0.741647,2.22414,0,0.743283,0,0,0.741987,0,0,0.737046,0,0,0.745944,0,0,0,0,0,0,0.747533,0,0,0.748288,0,0,0.74664,2.96762,0,0,0,0,0,0,2.24159,0.745944,0.742997,0,0.747897,0,0.748596,0,0.739235,0,0,0,0.743476,0,1.49443,0,1.49005,0.745684,0,1.4735,0.747589,0,0,0,0,0.746491,0,0.745342,0,0,0,0,0,2.97859,0,0.739454,0,1.47951,1.49525,1.49348,0.745443,0,0.745851,0,0,0,0,0,0.777172,0,1.48429,0,0,0.746965,0,0,0,0,0.745073,0,0.748811,2.99136,0.747421,0,0,0,0,0,0,0,0,0,0,0,0.748512,0,0,0,0,0.798414,0,0,0,0.731886,0,0.747906,0,0,0,0.746102,0,3.74102,0.731422,0.748372,0.727264,0,0.735583,0,0,0,0.728907,0.741987,0,0,0,0,0,0.742087,0,0,0.74883,0.738243,0,0,0,2.97759,0,0,0,0.743651,1.49559,0,0.748148,0.727476,0,0.748195,0.74625,0,1.49669,0,0,0.744094,0.730843,0,0,0.73193,1.4902,0,1.49796],[0,0,0,2.97608,1.99501,2.23817,0,0.742988,0.745768,0,0.746575,0,0.749008,2.98779,1.49671,0,0,0,0,0,0,0,1.44575,0,0,0.748662,0,1.45911,0,1.47969,0.774433,0,0,0.745194,1.48579,0,1.54151,0,0,0.744981,0,0,1.48329,0,1.4855,0,0,0,0.741987,0,0.74758,0.737046,0,0,0,0,1.49549,0,0.746287,0.744121,0.742988,1.49507,0,0,2.24486,0,0,2.23992,3.70952,0.995553,2.23833,0,0.747384,1.49404,0,0.747198,1.49189,0,0,0.747897,2.24573,0,0,2.2177,0,0,0.746835,0.743476,1.49304,0,0.733577,0.745027,0.745684,1.49308,0.736748,0,0,0,0,5.97937,2.23947,0,0.745342,1.49482,0,0,1.49274,0,0,0,2.95781,0,1.47951,0,0.746742,1.49089,0,0,0,1.4828,0.748858,0.749129,0,0,0,0.742143,0,0.747459,1.49393,0.751607,0,0.785433,0,0,0,2.24643,1.49568,5.97937,0,0,0,0.749138,0.749494,0.743062,0,1.54484,1.49794,0.830507,0,2.24554,1.49371,0.746696,0.74664,0,1.59683,1.48093,0,1.47787,0,0.746111,1.49581,1.48192,0,2.23895,0,0,4.48923,0.731422,2.24512,0,0,2.20675,0.743135,0,1.49161,1.45781,1.48397,1.49226,0.749372,0,0,0.748447,1.48417,0,0,0.74883,0.738243,0,0,0,1.4888,0.729803,0,0,0.743651,0.747794,0.74355,0,0.727476,0,0.748195,0,0,3.74172,0,0.746027,0.744094,0,0,2.24433,0,0,0,0.74898],[0,0,0,5.20814,2.992516,2.23817,0,0.742988,0.745768,0,0.746575,0,2.247028,2.98779,2.245064,1.494302,0,2.238809,0,0,0,0.737318,1.44575,1.49207,0,0.748662,1.48998,1.45911,1.496,1.47969,3.097733,0.737572,0,0.745194,2.228686,0,2.31226,0.743292,0.998502,0.744981,0,1.49674,2.224937,2.22414,1.4855,0.743283,0.741372,0,1.483974,0,0.74758,1.474092,0,0,0.745944,0,1.49549,0,0.746287,0.744121,1.48598,2.242603,0,0,2.993148,0,0,2.98656,7.41904,0.995553,2.23833,0,0.747384,2.24106,0,3.735988,3.72972,0.742997,0,1.495794,2.24573,0.748596,0,5.91388,0.743623,0,0.746835,1.486952,1.49304,1.49443,0.733577,2.235077,2.237054,1.49308,2.210248,1.495178,0,0,0,7.47421,2.985961,0,1.490684,1.49482,0,0,1.49274,0,3.723238,1.4806,4.43672,0.743329,2.95902,1.49525,2.240222,2.236333,0,0.745851,0,1.4828,0.748858,0.749129,0,0.777172,0,2.226433,0,0.747459,2.240895,0.751607,0,0.785433,0,0.745073,0,2.995241,5.23488,9.716481,0.741895,0,0,0.749138,0.749494,0.743062,0,1.54484,2.24691,0.830507,0,2.994052,1.49371,0.746696,0.74664,0,2.395244,1.48093,0.744611,1.47787,0.731886,0.746111,2.243716,2.22288,0,2.23895,0.746102,0,8.23025,1.462844,3.741862,1.454528,0,3.67792,0.743135,0,1.49161,2.186717,2.967947,1.49226,0.749372,0.748279,0,0.748447,2.226257,0,0.745823,1.49766,1.476486,0,0,0,5.95519,0.729803,0,0,1.487302,2.243384,0.74355,1.4963,1.454952,2.99184,1.49639,1.4925,0,5.98675,0,0.746027,2.232284,0.730843,2.2317,2.24433,0.73193,2.980401,0,2.24694]],"container":"<table class=\"display\">\n <thead>\n <tr>\n <th> <\/th>\n <th>focal<\/th>\n <th>compound<\/th>\n <th>birthyr<\/th>\n <th>obyear<\/th>\n <th>rank<\/th>\n <th>infant?<\/th>\n <th>attack_all<\/th>\n <th>chase_all<\/th>\n <th>threatcontact_all<\/th>\n <th>threatnocontact_all<\/th>\n <th>agg_in<\/th>\n <\/tr>\n <\/thead>\n<\/table>","options":{"columnDefs":[{"className":"dt-right","targets":[3,4,5,7,8,9,10,11]},{"orderable":false,"targets":0}],"order":[],"autoWidth":false,"orderClasses":false}},"evals":[],"jsHooks":[]}</script>
<p><br></p>
<p>Hmm…blogdown leaves me with yet another mystery. The datatable renders just fine within the RStudio IDE, but not when the site renders. How can this be?</p>
</div>
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ image:
focal_point: ''
preview_only: no
projects: []
disable_jquery: false
---

```{r include = FALSE}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
focal_point: ''
preview_only: no
projects: []
disable_jquery: false
---


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ image:
focal_point: ''
preview_only: no
projects: []
disable_jquery: false
---


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
focal_point: ''
preview_only: no
projects: []
disable_jquery: false
---


Expand Down
Loading

0 comments on commit 4f0009e

Please sign in to comment.