View prostate.Rmd
title output
Prostate Cancer
html_document
knitr::opts_chunk$set(echo = TRUE)

To Do

View gist:2f8bd10a1e4d47447d3cd2540aa28436
Verifying my Blockstack ID is secured with the address 17b9hyyeoVTZCwgmGQ7bYB3bZCo6NYqFdZ https://explorer.blockstack.org/address/17b9hyyeoVTZCwgmGQ7bYB3bZCo6NYqFdZ
View download-kaggle-data.py
import requests
# The direct link to the Kaggle data set
data_url = 'http://www.kaggle.com/c/digit-recognizer/download/train.csv'
# The local path where the data set is saved.
local_filename = "train.csv"
# Kaggle Username and Password
kaggle_info = {'UserName': "my_username", 'Password': "my_password"}
View pdf_two_cols_2_one_col.R
library(pdftools)
library(tesseract)
library(magick)
pdf_name <- "file_name.pdf" #Insert file name
pdf <- pdf_text(pdf_name)
num_pages = length(pdf)
#Function takes in a page, converts to an image, then splits it into halves and returns them
read_pdf_pages <- function(name_pdf, page_num, height, width){
View img.R
#http://www.fooledbyrandomness.com/SITG.html
library(pdftools)
library(tesseract)
library(magick)
library(purrr)
getwd()
pdf_name <- "equality.pdf"
View ghub_apps_access.py
#python version
import requests
res = requests.get('https://api.github.com/authorizations',
auth = ('<user-name>', '<password>'))
data = res.json()
set([x['app']['name'] for x in data])
#alternatively
#curl --user "<user-name>, <password>" https://api.github.com/authorizations
View curl.md

Introduction

An introduction to curl using GitHub's API.

The Basics

Makes a basic GET request to the specifed URI

curl https://api.github.com/users/caspyin
View sticker_maker.R
#Package Repo: https://github.com/GuangchuangYu/hexSticker
#Sticker Vendor: https://github.com/terinjokes/StickerConstructorSpec/wiki/Vendors
library(hexSticker)
library(png)
imgurl <- "https://68.media.tumblr.com/5183b41ae59aa0e0c71a7b9be63ac6c1/tumblr_ouc9w6G0He1vkkqe4o1_1280.png"
sticker(imgurl, #image
#package = "The Bicameral Mind", #name of sticker
View philosophy_bot.py
import glob
import markovify
import pickle
import tweepy
import settings_tweet as st
#Bot Creation
#Files consisted of five books downloaded fromthe Project Gutenberg website: 1) Beyong Good and Evil, 2) The Analysis of Mind,
#3) The Critique of Pure Reason, 4) The Prince, 5) The Republic. Cleaning of text done via https://github.com/catseye/Guten-gutter.