Skip to content

Instantly share code, notes, and snippets.

@kbjarkefur
kbjarkefur / 2018-11-08-continued-education-ado-files.md
Last active March 19, 2022 00:26
DIME Continued Education - November 08, 2018

How to write programs (also called commands or functions) in Stata

This is an introduction to how to write programs in Stata. To try this out yourself, download this Gist by clicking Download Zip. Unpack the .zip file and edit the path global in the runfile.do. Then follow these instructions and run the corresponding section of the run file.

If you have any questions or want us to add another examples on how you can expand myhist.ado as us in the comment section below.

Hello World

It is common in computer science that the first function/command you write is a simple command that just display the message Hello World!. That is what the program in hello_world.ado does.

@CollinChaffin
CollinChaffin / How_to_disable_ATT_DNS_Redirection.md
Created August 29, 2018 21:26
How to disable the very little-known AT&T setting that can appear to hijack your home DNS lookups and redirect to 104.239.207.44

How to disable the very little-known AT&T setting that can appear to hijack your home DNS lookups and redirect to 104.239.207.44

Issue

DNS queries on home network suddenly resolving hosts to 104.239.207.44.

Symptoms

You will see SPORADIC mis-resolutions of EVERYTHING to that 104.239.207.44 address if their crappy router happens to hear your PC's DHCP request - EVEN IF ANOTHER DHCP SERVER ON THE NETWORK assigns the ultimate address.

@specter119
specter119 / zot_rm_unmaintained_files.py
Last active March 11, 2024 11:05
remove files not maintained by zotero
#!/usr/bin/env python
# coding: utf-8
from __future__ import print_function
import configparser
import re
import shutil
import sqlite3
import sys
@bradtraversy
bradtraversy / webdev_online_resources.md
Last active June 10, 2024 18:48
Online Resources For Web Developers (No Downloading)
@aparrish
aparrish / a-reasonable-introduction.ipynb
Last active September 7, 2022 08:59
Workshop notebook. Code examples released under CC0 https://creativecommons.org/choose/zero/, other text released under CC BY 4.0 https://creativecommons.org/licenses/by/4.0/
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@akeaswaran
akeaswaran / pollscore.m
Last active November 8, 2019 23:54
Calculating poll score in CFC
-(void)updateStrengthOfWins {
int strWins = 0;
for ( int i = 0; i < gameSchedule.count; ++i ) {
Game *g = gameSchedule[i];
if (g.homeTeam == self) {
strWins += pow(60 - g.awayTeam.rankTeamPollScore,2);
} else {
strWins += pow(60 - g.homeTeam.rankTeamPollScore,2);
}
}
@eamartin
eamartin / notebook.ipynb
Last active November 6, 2022 18:53
Understanding & Visualizing Self-Normalizing Neural Networks
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@aparrish
aparrish / csv-intro.ipynb
Last active July 18, 2023 20:00
Quick intro to CSVs. Code examples released under CC0 https://creativecommons.org/choose/zero/, other text released under CC BY 4.0 https://creativecommons.org/licenses/by/4.0/
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.