Skip to content

Instantly share code, notes, and snippets.

View dmpe's full-sized avatar
💭
🎾

John dmpe

💭
🎾
View GitHub Profile
final TimerTask messageLabelStrengthTimerTask = new TimerTask() {
@Override
public void run() {
Platform.runLater(new Runnable() {
@Override
public void run() {
rootGroup.getChildren().remove(
labelStrength);
}
});
@dmpe
dmpe / gist:e96e9ba0d9d772c34fe5
Created July 21, 2014 20:54
Gist for buttons
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="Control Panel">
<title>CS Dashboard - Control panel</title>
<link href="css/bootstrap.min.css" rel="stylesheet">
<link href="css/styles.css" rel="stylesheet">
@dmpe
dmpe / BigTable.R
Created November 1, 2014 23:18
Analysis of Singapore's Education using three datasets
library("ggplot2")
source("PupilsPerTeacherRatio.R") # load our data
source("ExpenditurePerStudent_Pupils.R") # load the data
data = matrix(c(cleanedData.pupils$Years, cleanedData.pupils$ExpednInSD,
cleanedData.ratio$PupilsPerTeacher), ncol=3)
df = data.frame(data)
colnames(df) <- c("Year", "MoneySpend", "Ratio")
#TODO ggplot
@dmpe
dmpe / gist:76698d977c28314c02e3
Created June 21, 2015 10:19
Example of JSON-LD
{
"abstracts-retrieval-response":
{
"coredata":
{
<abstracts-retrieval-response><coredata><prism:url>http://api.elsevier.com/content/abstract/scopus_id/0037070197</prism:url><dc:identifier>SCOPUS_ID:0037070197</dc:identifier><eid>2-s2.0-0037070197</eid><pubmed-id>11852050</pubmed-id><prism:doi>10.1016/S0014-5793(01)03313-0</prism:doi><dc:title>The orientation of the antibiotic peptide maculatin 1.1 in DMPG and DMPC lipid bilayers. Support for a pore-forming mechanism</dc:title><prism:aggregationType>Journal</prism:aggregationType><srctype>j</srctype><citedby-count>44</citedby-count><prism:publicationName>FEBS Letters</prism:publicationName><source-id>17481</source-id><prism:issn>00145793</prism:issn><prism:volume>512</prism:volume><prism:issueIdentifier>1-3</prism:issueIdentifier><prism:startingPage>47</prism:startingPage><prism:endingPage>51</prism:endingPage><prism:pageRange>47-51</prism:pageRange><prism:coverDate>2002-02-13</prism:coverDate><dc:creator><author auid="55126316600" seq="1"><ce:initials>C.S.B.</ce:initials><ce:indexed-name>Chia C.S.B.</ce:ind
@dmpe
dmpe / returnData.R
Created September 7, 2015 16:43
returnData.R used for benchmarking RSocrata row binding
# An interface to data hosted online in Socrata data repositories
# This is the main file which uses other functions to download data from a Socrata repositories
#
# Author: Hugh J. Devlin, Ph.D et al. 2013-08-28
###############################################################################
# library("httr") # for access to the HTTP header
# library("jsonlite") # for parsing data types from Socrata
# library("mime") # for guessing mime type
# library("geojsonio") # for geospatial json
@dmpe
dmpe / test.R
Last active September 18, 2015 22:57
coursera Machine Learning
library(e1071)
library(rpart)
library(gbm)
library(randomForest)
library(caret)
library(foreach)
set.seed(5152)
pml.testing <- read.csv("PracticalML/project/pml-testing.csv", na.strings = c("NA", ""))
@dmpe
dmpe / tweetdeck.user.js
Created November 4, 2015 20:14
Delete TweetDeck's heart for the star (pre November 2015) | Greasemonkey user.js
// ==UserScript==
// @name Tweetdeck Permant
// @description Block that fucking heart on tweetdeck
// @namespace https://tweetdeck.twitter.com
// @include https://*.twitter.com/*
// @include https://tweetdeck.com/*
// @include https://tweetdeck.twitter.com/*
// @version 1.3
// @author https://github.com/dmpe | @dmpe | John Malc
// @grant none
library(shiny)
library(shinydashboard)
header <- dashboardHeader(
title = "Dashboard Demo",
# Dropdown menu for messages
dropdownMenu(
type = "messages",
badgeStatus = "success",
library(shiny)
library(shinydashboard)
header <- dashboardHeader(title = "Dashboard Demo")
body <- dashboardBody()
server <- function(input, output) {
}