This file contains 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
scatter.expectativas <- function(Variables, nombres = '', xmin = FALSE, obs = NA, reg = F) | |
{ | |
Datos <-read.csv('Encuestas.csv') | |
Datos <- subset(Datos, Datos$Horizonte %in% Variables, drop = TRUE) | |
Datos$FechaEnc <- as.Date(sapply(Datos$FechaEncuesta, as.fecha)) | |
if(xmin) Datos <- subset(Datos, Datos$FechaEnc >= xmin, drop = TRUE) | |
if(!is.na(obs)) Datos <- subset(Datos, Datos$FechaEnc %in% obs, drop = TRUE) | |
This file contains 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
# Paso 1. | |
# Descargar este archivo y extraer los contenidos en la carpeta XX | |
# http://mapserver.inegi.org.mx/MGN/mge2010v5_0a.zip | |
# Paso 2. | |
# Fijar el directorio de trabajo la carpeta XX en la que descargaste los archivos | |
setwd("d:/User Profiles/G13087/Documents/R/Mapas/INEGI/Estados") | |
# Paso 3. |
This file contains 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
# http://mapserver.inegi.org.mx/MGN/mge2010v5_0a.zip | |
setwd("d:/User Profiles/G13087/Documents/R/Mapas/INEGI/Municipios") | |
rm(list = ls()) | |
require("rgdal") | |
require("maptools") | |
require("ggplot2") | |
require("plyr") | |
require("rgeos") |
This file contains 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
# Jose Sotelo | |
# 2015 | |
# Universite de Montreal | |
import matplotlib.pyplot as plt | |
import numpy as np | |
# x = np.linspace(0, 3*np.pi, 500) | |
# plt.plot(x, np.sin(x**2)) | |
# plt.title('A simple chirp'); | |
# plt.show() |
This file contains 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
# coding: utf-8 | |
# In[ ]: | |
import re | |
import commands | |
import numpy as np | |
import scipy.io.wavfile | |
import itertools |
This file contains 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 theano | |
import numpy | |
from numpy.testing import assert_allclose | |
from collections import OrderedDict | |
from fuel.datasets import IndexableDataset | |
from fuel.streams import DataStream | |
from fuel.schemes import SequentialScheme | |
from theano import tensor |
This file contains 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
from theano import function | |
from blocks.bricks import MLP, Identity | |
from blocks.filter import VariableFilter | |
from blocks.initialization import Constant | |
from blocks.roles import INPUT | |
from blocks.utils import shared_floatx | |
from theano import function, tensor | |
from blocks.graph import ComputationGraph, apply_batch_normalization | |
import numpy |
This file contains 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 theano | |
import numpy | |
from collections import OrderedDict | |
from fuel.datasets import IndexableDataset | |
from fuel.streams import DataStream | |
from fuel.schemes import SequentialScheme | |
from theano import tensor |
This file contains 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
from theano import tensor | |
from theano.ifelse import ifelse | |
from blocks.utils import shared_like | |
from blocks.monitoring.aggregation import AggregationScheme, Aggregator | |
class MeanAndVariance(AggregationScheme): | |
"""Aggregation scheme which computes the mean. | |
Parameters | |
---------- | |
numerator : :class:`~tensor.TensorVariable` |
This file contains 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("igraph") | |
num_layer = 7 | |
num_nodes = (num_layer+1)*num_layer/2 | |
M <-matrix(rep(0,num_nodes*num_nodes),nrow=num_nodes,ncol=num_nodes) | |
layout <- matrix(rep(0, 2*num_nodes), nrow=num_nodes) | |
node = 0 | |
for(layer in 1:num_layer){ |
OlderNewer