sudo echo 'deb http://apt.postgresql.org/pub/repos/apt/ xenial-pgdg main' > /etc/apt/sources.list.d/pgdg.list
wget --quiet -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | \
sudo apt-key add -
sudo apt-get update
sudo apt-get install postgresql-9.6 postgresql-client-9.6 postgresql-contrib-9.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
| # Define the function | |
| loghistplot <- function(data) { | |
| require(ggplot2); require(gridExtra) # load packages | |
| names(data) <- c('x','y') # rename columns | |
| # get min and max axis values | |
| min_x <- min(data$x) | |
| max_x <- max(data$x) |
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
| 2006-1 | 8.040729483282673 | |
|---|---|---|
| 2006-2 | 8.00303951367781 | |
| 2006-3 | 8.016413373860182 | |
| 2006-4 | 8.010334346504559 | |
| 2006-5 | 8.012765957446808 | |
| 2006-6 | 7.9969604863221875 | |
| 2006-7 | 7.999392097264437 | |
| 2006-8 | 7.982370820668692 | |
| 2006-9 | 8.0370820668693 | |
| 2006-10 | 8.038297872340424 |
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 tensorflow as tf | |
| from tensorflow.examples.tutorials.mnist import input_data | |
| #import data | |
| mnist = input_data.read_data_sets("data/", one_hot=True) | |
| sess = tf.InteractiveSession() | |
| # Create the model | |
| x = tf.placeholder(tf.float32, [None, 784]) |
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
| library(MonteCarlo) | |
| df <- data.frame(x=c(2.2, 2.2, 2.2, 2.2, 2.2), y=c(2.2, 1.2, 1.3, 2.4, 2.6)) | |
| df$trend <- seq(1,length(df$x)) | |
| pv <- function(noparams) { | |
| return(list("p.value"=cor(jitter(df$x), df$y))) | |
| } | |
| param_list <- list("noparams"=c(0)) |
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
| KCNB1 | |
| GNAS | |
| PRPF4B | |
| INTS6 | |
| CACNA1C | |
| HNRNPA0 | |
| DHX8 | |
| UBTF | |
| SMARCA4 | |
| ZNF768 |
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
| var real_docwrite = document.write, | |
| body = $('body'); | |
| (function insertGists(a_tags) { | |
| if (a_tags.length > 0) { | |
| a_tag = a_tags.shift() | |
| document.write = function(stylesheet) { | |
| $('head').append(stylesheet); | |
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
| package typesizes | |
| import ( | |
| "math" | |
| "strconv" | |
| "testing" | |
| ) | |
| var N int = 1e7 | |
| var stringSize int = 1 + int(math.Log10(float64(N))) |
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 Foundation | |
| import Alamofire | |
| public enum Router:URLRequestConvertible { | |
| public static let baseUrlString:String = "http://testapi.example.com" | |
| case Upload(fieldName: String, fileName: String, mimeType: String, fileContents: NSData, boundaryConstant:String); | |
| var method: Alamofire.Method { | |
| switch self { | |
| case Upload: |
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
| package poison | |
| import ( | |
| "database/sql" | |
| "reflect" | |
| "github.com/gorilla/schema" | |
| ) | |
| // Convertors for sql.Null* types so that they can be |