# Blog Posts

Explaining to my parents what I do

My parents don't understand what I do as a quant, so I wrote this to help explain to them. This post goes into the basics of power pricing.

January 8, 2022 - quant, research, economics, math, optimization, power

How To Derive Useful Financial Approximations

Many useful financial rules of thumb can be derived using Taylor approximations. In this blog post, I solve for common approximation formulas.

October 15, 2020 - finance, approximation, taylor, bond yield, derive, rule of four, rule of 72

A Few Catchy Philosophy Quotes That Are Often Misinterpreted

In this post, I dissect a few popular quotes from philosophy by working through the original literature. These quotes are often misinterpreted.

July 8, 2020 - philosophy, Aristotle, Nietzsche

Three Controversial Beliefs About Living Things

I describe a few of my more unusual beliefs about evolution and the nature of living things. I think that evolution is frequently misunderstood.

October 23, 2019 - philosophy, philosophy of science, evolution, biology

How to train a neural net to play cards

In this article, I use a modified version of Q-learning to train a bot to play the card game Literature. Specifically, I use a neural net to approximate rewards with some shortcuts to speed up training.

September 1, 2019 - machine learning, cards, neural net, artificial intelligence, q-learning

Analyzing "Are You the One?"

In the MTV show "Are You the One?", contestants are secretly assigned to pairs and attempt to find their mate. In this post, I'll explore some of the probability behind the show.

August 11, 2019 - probability, combinatorics, game theory, statistics

What you don't learn in school about production Python

There are some major differences that separate production-quality Python code from what you write in school. In this article, I discuss code style, type checking, testing, and more.

June 29, 2019 - production, python, style, tips, conventions

Using Chebyshev points for Lagrange interpolation

It might be tempting to pick equidistant points when using Lagrange interpolation. But because of the Runge phenomenon, you're often better off picking Chebyshev nodes instead.

March 5, 2019 - chebyshev, lagrange, interpolation, python

Executing HTTP requests in parallel with asyncio

Python can be written in an asynchronous way by using asyncio. In this article, we'll demonstrate how to run multiple HTTP requests in parallel.

June 9, 2018 - asyncio, python, asynchronous, http

Making a simple HTTP server with sockets

In this blog post, we’ll set up a very simple Unix HTTP server in C using sockets. This tutorial covers opening the socket for the server, along with writing the HTTP response.

October 15, 2017 - simple, sockets, server, http, c

Writing a tic-tac-toe solver using minimax

In this post, we'll build a tic-tac-toe solver in Python, using the minimax algorithm. We'll go through constructing a game tree, but we won't add alpha-beta pruning.

September 6, 2017 - minimax, tic-tac-toe, solver, artificial intelligence

Getting started with WebSockets in Tornado

In this article, we build a simple application using WebSockets with the Tornado platform. The application sends messages to multiple connected clients.

August 22, 2017 - tornado, python, websockets, simple

How to SSH tunnel to a Docker container on a remote server

If you're running a web server in a Docker container on a remote server, you might want to map a port on your computer to the web server within the Docker container. This tutorial breaks down the process into two steps.

May 4, 2017 - docker, ssh tunnel, port forward, forwarding, container

Sometimes you need to access GitHub directly from its IP address. For example, on Oct. 21, the Dyn DNS service went out, and GitHub's domain no longer resolved to the IP. This tutorial walks you through editing your hosts file.

October 21, 2016 - hosts, dns, github, dyn, outage

Setting up Flask with Red Hat on AWS

Setting up Flask varies depending on the operating system. In this example, I walk through how to set up an Apache server, and then a Flask server in Python on Red Hat Enterprise Linux (RHEL). The same principles apply to other Linux distros.

October 16, 2016 - flask, red hat, rhel, python, aws

How to get MacTeX faster: Easily using BasicTeX

LaTeX, and the macOS distribution MacTeX, can save you a significant amount of time, but the MacTeX download is huge. BasicTeX is a lightweight alternative that offers many of the same benefits. You can easily get started with this tutorial.

April 15, 2016 - basictex, mactex, latex, install

Accessing AWS Elastic Beanstalk through macOS Finder

While SSH and the EB CLI are fast, sometimes you want visual feedback when accessing your EC2 instance with Elastic Beanstalk. Using sshfs, you can access the EC2 filesystem and mount it onto your local machine, despite having an unreliable IP address.

April 15, 2016 - elastic beanstalk, finder, sshfs, amazon web services, ssh

Using custom domains with AWS Elastic Beanstalk

When configuring Amazon Web Services, Elastic Beanstalk is a great option. At the same time, you don't want to pay an absurd amount for emails or HTTPS. In this tutorial, we find an affordable way to seamlessly forward emails and redirect users to your site.

April 14, 2016 - elastic beanstalk, amazon web services, custom domain, route 53, email forwarding

Simple Facebook PHP SDK 4 tutorial

The Facebook SDK 4 documentation for PHP is vague and doesn't fully explain how to get started. With this tutorial you'll use the Facebook SDK and gain an understanding of how to get data you need. In the example we fetch the user's most recent photo.

July 8, 2014 - facebook sdk, php, tutorial, sdk 4, simple, example, permissions

Scraping the web with PHP

So many websites fail to provide developers with APIs, and those that do sometimes neglect to update them. One of the ways to get the data that you need is by directly scraping the HTML files themselves. This is accomplished with PHP, cURL and the HTML DOM.

May 18, 2014 - web scraping, php, indexing, web harvesting, search spider, big data

Making pretty calendars with jQuery

Calendars are tricky. While you definitely need a robust calendar, an attractive design can leave a lasting impression on a user. With jQuery and the plugin Pretty Calendar, you can easily generate beautiful calendars in just a few logical lines of code.

April 19, 2014 - jquery, calendar, prettycalendar, javascript calendar, flexible

What is the best time to post on Facebook?

The most effective way of getting more likes is to post when your audience is active. This Chrome extension tracks how many of your Facebook friends are active and generates a graph of the results. You can easily see trends and time your posts accordingly.

April 5, 2014 - best time to post, facebook, what is the best time, most users active

Page 1 - 4

All code that is referenced or shown in this blog is covered under the MIT License unless otherwise stated.