Skip to content

Instantly share code, notes, and snippets.

View jtrain's full-sized avatar
🏠
Working from home

jtrain

🏠
Working from home
View GitHub Profile
@jtrain
jtrain / qv.csv
Created July 2, 2012 17:55
QV curve data for bus number 20001
V Q
0.87 0
0.88 -50
0.89 -75
0.9 -90
0.905 -98
0.91 -103
0.92 -105
0.93 -106
0.94 -107
@jtrain
jtrain / embedly.fluid.js
Last active December 17, 2015 13:39
Embedly's iframe in a fluid layout using inline replace.
(function() {
window.embedlyFluid = function(selector, key, options) {
$(selector).each(function() {
// set the video to the width of the parent container
var width = $(this).parent().width();
defaults = {
secure: true
import psspy
psspy.throwPsseExceptions = True
def ierr_doc(psspyFunc, ierr):
if not ierr:
return ''
# Find all the errors documented in the doc string
errDoc = psspyFunc.__doc__[psspyFunc.__doc__.find('IERR = 0'):]
errs = {}
@jtrain
jtrain / child.py
Created January 9, 2014 23:31
Spawn a long-lived process outside of PSS/E
"""
Child thread
constantly writes to a file for 60 seconds
"""
from __future__ import with_statement
import time
FILE = 'demo.txt'

Keybase proof

I hereby claim:

  • I am jtrain on github.
  • I am jervis (https://keybase.io/jervis) on keybase.
  • I have a public key whose fingerprint is 1AC9 A2AB F8E0 8326 F2AF 9920 68EB 6C8F DB03 5FD6

To claim this, I am signing this object: