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
library(gutenbergr) | |
library(tidytext) | |
library(dplyr) | |
library(ggplot2) | |
# Using Dracula as our example text, download it from Project Gutenberg | |
dracula<-gutenberg_download(345) | |
# Split each line of text into individual words | |
dracula<-dracula%>% |
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
# Our function to test | |
def above_freezing(celcius): | |
""" (int) -> boolean | |
Return True if celcius is above zero, and False if not | |
""" | |
return celcius > 0 | |
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
# Import the libraries used | |
library(gutenbergr) | |
library(tidytext) | |
library(dplyr) | |
library(ggplot2) | |
# Download text from Project Gutenberg | |
dracula<-gutenberg_download(345) | |
# Split the lines of text into words |
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
def bubble_sort(L): | |
for i in range(len(L)-1, 0, -1): | |
for j in range(i): | |
if L[j] > L[j+1]: | |
temp = L[j] | |
L[j] = L[j+1] | |
L[j+1] = temp | |
def selection_sort(L): |
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
library(gutenbergr) | |
library(tidytext) | |
library(dplyr) | |
library(wordcloud2) | |
dracula<-gutenberg_download(345) | |
dracula$gutenberg_id<-NULL | |
dracula<-dracula%>% | |
unnest_tokens(word, text) |
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
library(gutenbergr) | |
library(tidytext) | |
library(dplyr) | |
library(wordcloud) | |
dracula<-gutenberg_download(345) | |
dracula$gutenberg_id<-NULL | |
dracula<-dracula%>% | |
unnest_tokens(word, text) |
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
\documentclass{beamer} | |
\begin{document} | |
\title{Positive and Negative Words in Dracula} | |
\author{Ron Richardson} | |
\begin{frame} | |
\titlepage |
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
#!/bin/bash | |
echo "deb https://dl.bintray.com/sbt/debian /" | sudo tee -a /etc/apt/sources.list.d/sbt.list | |
sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv 2EE0EA64E40A89B84B2DF73499E82A75642AC823 | |
sudo apt-get update | |
sudo apt-get install sbt | |
OlderNewer