Skip to content

Instantly share code, notes, and snippets.

View SuperJohn's full-sized avatar

John Houghton SuperJohn

  • Super John Inc
  • San Diego, CA
View GitHub Profile
@SuperJohn
SuperJohn / bash_reference.sh
Created April 4, 2021 18:43
My favorite Bash Reference / Cheat Sheet
#!/bin/bash
##############################################################################
# SHORTCUTS
##############################################################################
CTRL+A # move to beginning of line
CTRL+B # moves backward one character
CTRL+C # halts the current command
CTRL+D # deletes one character backward or logs out of current session, similar to exit
@SuperJohn
SuperJohn / .gitignore
Created February 17, 2019 10:28 — forked from ELLIOTTCABLE/.gitignore
BASH Script to keep Route53 updated with your current external IP address
*.ip
*.log
@SuperJohn
SuperJohn / skills_chart.md
Created November 21, 2018 10:10
a reall new cool gist

title: "Skills Chart" author: "John Houghton" date: "11/21/2018" output: html_document


title: "Portfolio Optimization & Rebalancing Tool" author: "John Houghton" #output: #html_document: #code_folding: hide #df_print: kable #number_sections: yes #theme: cosmo #toc: yes

@SuperJohn
SuperJohn / jupyter_notebook_test.ipynb
Last active November 15, 2017 23:06
jupyter_notebook_test
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@SuperJohn
SuperJohn / jupyter_userdata.sh
Created November 1, 2016 01:19 — forked from frangipane/jupyter_userdata.sh
configure jupyter notebook server (to be passed as user data when you launch an aws ec2 instance)
#!/bin/bash
CERTIFICATE_DIR="/home/ubuntu/certificate"
JUPYTER_CONFIG_DIR="/home/ubuntu/.jupyter"
if [ ! -d "$CERTIFICATE_DIR" ]; then
mkdir $CERTIFICATE_DIR
openssl req -x509 -nodes -days 365 -newkey rsa:1024 -keyout "$CERTIFICATE_DIR/mykey.key" -out "$CERTIFICATE_DIR/mycert.pem" -batch
chown -R ubuntu $CERTIFICATE_DIR
fi
@SuperJohn
SuperJohn / forecasting.r
Created October 31, 2016 22:25
forecasting in R
# load some data
forecast_data <- structure(c("28", "42", "21", "23", "29", "15", " 8", " 4", " 2",
" 1", NA, NA, NA, NA, NA, "26", "39", "20", "22", "28", "14",
" 7", " 4", " 2", NA, NA, NA, NA, NA, "43", "65", "33", "36",
"45", "23", "12", NA, NA, NA, NA, NA, NA, NA, "58", "87", "44",
"48", "60", NA, NA, NA, NA, NA, NA, NA, NA, "37", "56", "28",
"31", NA, NA, NA, NA, NA, NA, NA, NA, NA, "28", "42", "21", NA,
NA, NA, NA, NA, NA, NA, NA, NA, NA, "19", "29", NA, NA, NA, NA,
NA, NA, NA, NA, NA, NA, NA, "24"), .Dim = c(12L, 8L), .Dimnames = list(
c("Wk.1", "Wk.2", "Wk.3", "Wk.4", "Wk.5", "Wk.6", "Wk.7",