Skip to content

Instantly share code, notes, and snippets.

View ronsims2's full-sized avatar
🏀
Ballin'

Ron Sims II ronsims2

🏀
Ballin'
View GitHub Profile
{
"name": "JSON",
"weapon": "machete",
"home": "crystal lake",
"likes": "kill kill kill",
"hates": "you"
}
@ronsims2
ronsims2 / foo.json
Last active July 8, 2016 20:58
Dummy JSON data for AJAX test
This file has been truncated, but you can view the full file.
[
{
"_id": "5780137d86c3e01e6396f8af",
"index": 0,
"guid": "fa5e60f5-e8cc-4697-8056-7c51225292b8",
"isActive": false,
"balance": "$2,003.16",
"picture": "http://placehold.it/32x32",
"age": 26,
"eyeColor": "green",
@ronsims2
ronsims2 / main.m
Created August 25, 2016 13:21
Example of how to left pad in Objective-C
//
// main.m
// testcode
//
// Created by Ron Sims II on 6/6/16.
// Copyright © 2016 Ron Sims II. All rights reserved.
//
#import <Foundation/Foundation.h>
@ronsims2
ronsims2 / filemover.sh
Last active October 25, 2016 21:27
A shell script that archives files
#!/bin/bash
#A list of file names
clear
#Read by line to handle filenames with spaces
OGIFS = $IFS
IFS=$(echo -en "\n\b")
myfiles=$(ls)
@ronsims2
ronsims2 / d3-simon.js
Created December 23, 2016 01:35
Simon says for d3 donut charts
(function() {
var shuffle = function(items) {
var newOrder = [];
var usedNumbers = {};
var i = 0;
while (newOrder.length < items.length) {
i++;
var rando = Math.floor(Math.random() * items.length);
if (!usedNumbers[rando.toString()]) {
usedNumbers[rando.toString()] = true;
@ronsims2
ronsims2 / index.html
Created December 25, 2016 02:42 — forked from anonymous/index.html
Flashcards Flashcards // source https://jsbin.com/zutape
<!DOCTYPE html>
<html>
<head>
<link href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css" rel="stylesheet" type="text/css" />
<meta name="description" content="Flashcards">
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>Flashcards</title>
<style id="jsbin-css">
.card-back {
@ronsims2
ronsims2 / data.csv
Created February 3, 2017 20:48
sample d3 data
date close
1-May-12 58.13
30-Apr-12 53.98
27-Apr-12 67.00
26-Apr-12 89.70
25-Apr-12 99.00
24-Apr-12 130.28
23-Apr-12 166.70
20-Apr-12 234.98
19-Apr-12 345.44
@ronsims2
ronsims2 / fiore.js
Last active March 13, 2017 02:29
A helper program for using the College Scorecard API https://collegescorecard.ed.gov/data/documentation/
import $ from 'jquery';
class fiore {
constructor(apkiKey, url) {
this.apiKey = apiKey;
this.url = url;
this.schoolName = '';
this.school = null;
}
@ronsims2
ronsims2 / sample-data.csv
Last active April 7, 2017 18:41
Sampel data for the educational graphing library
date data_loud_talking data_loutering data_horseplay
03-17-2017 42 65 79
03-18-2017 39 13 103
03-19-2017 78 2 -5
03-20-2017 12 96 22
03-21-2017 5 11 7
03-22-2017 99 5 7
03-23-2017 10 70 9
03-24-2017 33 51 40
03-25-2017 32 22 62
@ronsims2
ronsims2 / plomni.js
Last active March 22, 2017 14:11
D3 v4 dependent object for quick chart creation.
(function() {
var chart = function(config) {
this.svg = null;
this.g = null;
this.colors = config.colors || ['crimson', 'coral', 'yellow', 'seagreen', 'skyblue', 'violet', 'mediumorchid'];
this.height = config.height || 300;
this.width = config.width || 400;
this.marginTop = config.marginTop || 50;
this.marginBottom = config.marginBottom || 50;
this.marginLeft = config.marginLeft || 50;