{{ message }}

Instantly share code, notes, and snippets.

Last active Apr 3, 2017
View circulo.R
 library('ggplot2') f_circulo <- function() { # Generar 500 puntos de 0pi radianes a 2pi radianes, # lo cuales equivalen a 0 y 360 grados respectivamente. t <- seq( from = 0, to = 2 * pi, length.out = 1000 ) # Generar un circulo con ecuaciones parametricas
Last active Apr 3, 2017
View dardosTrend.R
 library('ggplot2') f_lanzar <- function( p_dardos ) { # Radio = 1. r <- 1 # Generar n puntos (x,y) por medio de una distribucion uniforme. x <- runif( min = -1, max = 1, n = p_dardos )
Last active Apr 3, 2017
View dardos.R
 library('ggplot2') f_lanzar <- function( p_dardos ) { # Radio = 1. r <- 1 # Generar n puntos (x,y) por medio de una distribucion uniforme. x <- runif( min = -1, max = 1, n = p_dardos )
Created Nov 9, 2016
View auxiliaryPlot.R
 library('ggplot2') # Dataset column names and classes l_colnames = c( 'game_no','stadium', 'team', 'x_cord', 'y_cord', 'desc' ) l_colClasses = c( 'numeric', 'character', 'character', 'numeric', 'numeric', 'character' ) # Load the dataset hip_data <- read.csv( file = 'hitsPerGame.csv' , header = F , col.names = l_colnames
Created Nov 9, 2016
View createPlot.R
 library('ggplot2') # Dataset column names and classes. l_colnames = c( 'game_no','stadium', 'team', 'x_cord', 'y_cord', 'desc' ) l_colClasses = c( 'numeric', 'character', 'character', 'numeric', 'numeric', 'character' ) # Load the dataset. hip_data <- read.csv( file = 'hitsPerGame.csv' , header = F , col.names = l_colnames
Created Nov 9, 2016
View scrapMLBAM.py
 from lxml import etree import glob import csv # Input Files. hipFiles = glob.glob('*hip.xml') gameFiles = glob.glob('*data.xml') # Output File. csvFile = open('hitsPerGame.csv', 'wb')
Last active Apr 3, 2017