Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# uses dev version of 'waffle' | |
# devtools::install_github("leeper/waffle@patch-1") | |
library("waffle") | |
library("extrafont") | |
# population | |
set.seed(1) | |
N <- 900L | |
p <- c("Small Group 1" = 30, "Big Group 1" = 420, "Small Group 2" = 30,"Big Group 2" = 420) | |
glyph <- c("male", "female")[sample(1:2, N, TRUE)] |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
""" | |
Example of using Keras to implement a 1D convolutional neural network (CNN) for timeseries prediction. | |
""" | |
from __future__ import print_function, division | |
import numpy as np | |
from keras.layers import Convolution1D, Dense, MaxPooling1D, Flatten | |
from keras.models import Sequential |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# | |
# mnist_cnn_bn.py date. 5/21/2016 | |
# date. 6/2/2017 check TF 1.1 compatibility | |
# | |
from __future__ import absolute_import | |
from __future__ import division | |
from __future__ import print_function | |
import os |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## There's a dependency on https://github.com/JohnLangford/vowpal_wabbit | |
library(plyr) | |
library(dplyr) | |
library(magrittr) | |
library(pander) | |
panderOptions('table.split.table', Inf) | |
LOW_MEAN <- .4 | |
HIGH_MEAN <- .6 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import scala.collection.immutable.Queue | |
object Median { | |
sealed trait State { | |
def count: Long | |
def add(item: Long): State | |
def median: Long | |
} | |
case class Start(window: Queue[Long], max: Int, countInt: Int) extends State { | |
def count = countInt |