Slide 1

Slide 1 text

1 MAKING WEBSITES Jeff Goldsmith, PhD Department of Biostatistics

Slide 2

Slide 2 text

2 • Just kidding, we all know what a website is What is a web site …??

Slide 3

Slide 3 text

2 • Just kidding, we all know what a website is – …Or do we? What is a web site …??

Slide 4

Slide 4 text

2 • Just kidding, we all know what a website is – …Or do we? • For our purposes a website is a collection of related pages, written in HTML, hosted on a server, and retrievable using an easy-to-remember name What is a web site …??

Slide 5

Slide 5 text

3 • Personal site, so people (employers) can find you • Site for a project • Site for an R package • I dunno, you want to blog? Why do I need to make one?

Slide 6

Slide 6 text

4 Do I need to know HTML?

Slide 7

Slide 7 text

4 • Of course not, this isn’t 1997 and you’re not putting a website on geocities Do I need to know HTML?

Slide 8

Slide 8 text

4 • Of course not, this isn’t 1997 and you’re not putting a website on geocities Do I need to know HTML? (Golden age of the internet)

Slide 9

Slide 9 text

5 • R Markdown renders content (with or without R code) to several formats, including HTML • That is, you can write a detailed website using only R • Occasionally, knowing some HTML will get you out of trouble, but it’s not necessary for a lot of stuff Plus you already know RMD

Slide 10

Slide 10 text

---
 title: "My awesome website"
 output: 
 html_document:
 toc: true
 toc_float: true
 theme: cerulean
 ---
 # This is Jeff's awesome website
 
 ![](https://media.giphy.com/media/ drXGoW1iudhKw/giphy.gif) rmarkdown (Slide stolen from Jeff Leek)

Slide 11

Slide 11 text

---
 title: "My awesome website"
 output: 
 html_document:
 toc: true
 toc_float: true
 theme: cerulean
 ---
 # This is Jeff's awesome website
 
 ![](https://media.giphy.com/media/ drXGoW1iudhKw/giphy.gif) rmarkdown (Slide stolen from Jeff Leek)

Slide 12

Slide 12 text

7 • R Markdown can be used to build the website, but you still have to host it for other people to be able to find it • Lots of places let you host things for free now, including GitHub – Repository = website – Domain names are well-structured – New pushes to remote are reflected in the web site – Easy collaboration on websites for projects Knowing RMD is half the battle

Slide 13

Slide 13 text

8 • A lot like your “standard” workflow: – Create repo + R Project – Copy template website into the directory – Edit repo settings so GitHub knows this is a website – Edit content and push Workflow for websites