Skip to content

Instantly share code, notes, and snippets.

Keybase proof

I hereby claim:

  • I am ryanleeallred on github.
  • I am ryanallred (https://keybase.io/ryanallred) on keybase.
  • I have a public key ASDuatA3YkspjIT9EbT-qzX13S4PH_SPlsBJ4KWGtXR7KQo

To claim this, I am signing this object:

@ryanleeallred
ryanleeallred / user.html
Created July 13, 2022 09:05
user.html for Twittoff App Project
{% extends "base.html" %}
{% block content %}
<div id="user-info">
<p>{{ title }}</p>
<p>{{ message }}</p>
</div>
<div id="user-tweets">
{% for tweet in tweets %}
@ryanleeallred
ryanleeallred / prediction.html
Created July 13, 2022 09:04
prediction.html file for Twittof App Project
{% extends "base.html" %}
{% block content %}
<div id="prediction">
<p>{{ title }}</p>
<p>{{ message }}</p>
</div>
{% endblock %}
@ryanleeallred
ryanleeallred / base.html
Created July 13, 2022 09:03
base.html version 2 for module 3 of the Twitoff App Project.
<!DOCTYPE html>
<html>
<head>
<title>TwitOff - {{ title }}</title>
<link rel="stylesheet" href="https://unpkg.com/picnic" />
</head>
<body>
<nav>
@ryanleeallred
ryanleeallred / base.html
Created July 13, 2022 08:52
base.html file for Twitoff Flask App
<!DOCTYPE html>
<html>
<head>
<title>TwitOff - {{ title }}</title>
<link rel="stylesheet" href="https://unpkg.com/picnic" />
</head>
<body>
<nav>
<a href="/" class="brand"><span>TwitOff!</span></a>
<!-- responsive-->
@ryanleeallred
ryanleeallred / dataframe_example.py
Last active July 13, 2022 08:10
Example code for BloomTech Data Science Unit 3 Sprint 1 Module 2
import pandas as pd
# Build my class of type DataFrame
# df holds a new DataFrame "object"
# when I create a new object and save it to a variable
# I say that I have "instantiated" that object
df = pd.DataFrame({'a': [1,2,3], 'b': [4,5,6]})
if __name__ == "__main__":
{"businesses": [{"id": "JFU4VdpwzhE3I7o8ck3yzw", "alias": "beto-s-mexican-grill-salt-lake-city", "name": "Beto\u2019s Mexican Grill", "image_url": "https://s3-media2.fl.yelpcdn.com/bphoto/BGLnE0dTMWXRMUFf4SoMdQ/o.jpg", "is_closed": false, "url": "https://www.yelp.com/biz/beto-s-mexican-grill-salt-lake-city?adjust_creative=xokjsYdkvvDB_clvPE2mew&utm_campaign=yelp_api_v3&utm_medium=api_v3_business_search&utm_source=xokjsYdkvvDB_clvPE2mew", "review_count": 40, "categories": [{"alias": "mexican", "title": "Mexican"}], "rating": 2.0, "coordinates": {"latitude": 40.760975298871, "longitude": -111.878458552746}, "transactions": ["delivery"], "price": "$", "location": {"address1": "435 E 400th S", "address2": "", "address3": "", "city": "Salt Lake City", "zip_code": "84111", "country": "US", "state": "UT", "display_address": ["435 E 400th S", "Salt Lake City, UT 84111"]}, "phone": "+18013630788", "display_phone": "(801) 363-0788", "distance": 4180.668996298476}, {"id": "MEz9-PGteG0O3o-0XKR3tQ", "alias": "betos-mexica
Object {
"alias": "beto-s-mexican-grill-salt-lake-city",
"categories": Array [
Object {
"alias": "mexican",
"title": "Mexican",
},
],
"coordinates": Object {
"latitude": 40.760975298871,
@ryanleeallred
ryanleeallred / ztw
Created November 18, 2021 16:59
ZoomToWistia - FAILURE: Build failed with an exception. * What went wrong: Execution failed for task ':compileJava'.
(base) ryanallred@Ryans-MacBook-Air Desktop % cd ZoomToWistia
(base) ryanallred@Ryans-MacBook-Air ZoomToWistia % fswatch -0 -vx --event Renamed ~/Documents/Zoom | xargs -0 -n 1 bash runner
register_signal_handlers: SIGTERM handler registered.
register_signal_handlers: SIGABRT handler registered.
register_signal_handlers: SIGINT handler registered.
start_monitor: Adding path: /Users/ryanallred/Documents/Zoom
create_stream: Creating FSEvent stream...
run: Scheduling stream with run loop...
run: Starting event stream...
run: Starting run loop...
# Find the actual file to download
# From navigating the page, clicking "Data Folder"
# Right click on the link to the dataset and say "Copy Link Address"
flag_data_url = 'https://archive.ics.uci.edu/ml/machine-learning-databases/flags/flag.data'
# You can "shell out" in a notebook for more powerful tools
# https://jakevdp.github.io/PythonDataScienceHandbook/01.05-ipython-and-shell-commands.html
# Funny extension, but on inspection looks like a csv