-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
e3ab65a
commit 922ccbc
Showing
96 changed files
with
17,382 additions
and
0 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
tinytex::install_tinytex() | ||
#-----Practica 2 | ||
#----Ejercicio1a ----- | ||
library(dplyr) | ||
library(tidyr) | ||
library(ggplot2) | ||
library(lubridate) | ||
library(fpp3) | ||
library(slider) | ||
library(seasonal) | ||
data(canadian_gas) | ||
canadian_gas | ||
autoplot(canadian_gas, Volume) + | ||
ylab("volumen")+ | ||
xlab("fecha") + | ||
ggtitle("produccion nacional de gas en canada") | ||
dcmp_can <- canadian_gas %>% | ||
model(STL(Volume)) | ||
dcmp_can | ||
# Componente trend-cycle | ||
canadian_gas %>% autoplot(Volume, color='gray') + | ||
autolayer(components(dcmp_can), trend, color='blue') + | ||
xlab("fecha") + ylab("volumen") + | ||
ggtitle("Produccion de Gas Canada - Tendencia") | ||
#hay una tendencia del crecimiento y del decrecimiento en la produccion del gas, se puede observar que la tendencia es de manera ascendente, se puede observar a su ves que hay fluctuaciones estructurales que afectan a la producion de gas | ||
# Datos ajustados por estacionalidad | ||
canadian_gas %>% | ||
autoplot(Volume, color='gray') + | ||
autolayer(components(dcmp_can), season_adjust, color='green') + | ||
xlab("fecha") + ylab("volumen") + | ||
ggtitle("Produccion de Gas Canada - Desestacionalizado") | ||
#se tiene un aumento general en la produccion de gas con ligeras fluctuaciones estacionales | ||
#Graficos extras (no se como interpretarlas) | ||
gg_season(canadian_gas,Volume)+ | ||
labs(tittle="Estacionalidad Gas Canada", | ||
y="volumen", | ||
x="mes") | ||
#el volumen de produccion varia segun el mes, se puede observar un patron estacional dado que en las epocas de invierno este incrementa y en la temporada de verano este tiende a disminuir | ||
gg_season(canadian_gas, Volume, polar = TRUE) + | ||
labs(title = "Estacionalidad Gas Canada (Polar)", | ||
y = "Volumen", | ||
x = "Mes") | ||
#----Ejercicio 1b----- | ||
x11_dcmp_can <- canadian_gas %>% | ||
model(x11 = X_13ARIMA_SEATS(Volume ~ x11())) | ||
x11_dcmp_can | ||
x11_component_can <- components(x11_dcmp_can) | ||
head(x11_component_can,10) | ||
autoplot(x11_component_can) + labs(title = "Decomposicion de la produccion total de canada using X-11.") | ||
x11_component_can %>% ggplot(aes(x = Month)) + | ||
geom_line(aes(y = Volume, colour = "Data")) + | ||
geom_line(aes(y = season_adjust, colour = "Seasonally Adjusted")) + | ||
geom_line(aes(y = trend, colour = "Trend")) + | ||
labs(y = "Produccion Gas", title = "Produccion de gas Canada") + | ||
scale_colour_manual(values = c("gray", "#0072B2", "#D55E00"), | ||
breaks = c("Data", "Seasonally Adjusted", "Trend")) | ||
x11_component_can %>% | ||
gg_subseries(seasonal) |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
{ | ||
"hash": "9f688feee93c9d5bc4f7d750fe4e917e", | ||
"result": { | ||
"engine": "knitr", | ||
"markdown": "# Bienvenida {.unnumbered}\n\nThis is a Quarto book.\n\nTo learn more about Quarto books visit <https://quarto.org/docs/books>.\n\n\n::: {.cell}\n\n```{.r .cell-code}\n1 + 1\n```\n\n::: {.cell-output .cell-output-stdout}\n\n```\n[1] 2\n```\n\n\n:::\n:::\n", | ||
"supporting": [], | ||
"filters": [ | ||
"rmarkdown/pagebreak.lua" | ||
], | ||
"includes": {}, | ||
"engineDependencies": {}, | ||
"preserve": {}, | ||
"postProcess": 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
{ | ||
"hash": "f878a345de1703db0e940d24bf6c7523", | ||
"result": { | ||
"engine": "knitr", | ||
"markdown": "# Introducción\n\nThis is a book created from markdown and executable code.\n\nSee @knuth84 for additional discussion of literate programming.\n\n\n::: {.cell}\n\n```{.r .cell-code}\n1 + 1\n```\n\n::: {.cell-output .cell-output-stdout}\n\n```\n[1] 2\n```\n\n\n:::\n:::\n", | ||
"supporting": [], | ||
"filters": [ | ||
"rmarkdown/pagebreak.lua" | ||
], | ||
"includes": {}, | ||
"engineDependencies": {}, | ||
"preserve": {}, | ||
"postProcess": true | ||
} | ||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
{ | ||
"hash": "3febd69255a43159ce5a13968b282099", | ||
"result": { | ||
"engine": "knitr", | ||
"markdown": "# Índice\n\nIn summary, this book has no content whatsoever.\n\n\n::: {.cell}\n\n```{.r .cell-code}\n1 + 1\n```\n\n::: {.cell-output .cell-output-stdout}\n\n```\n[1] 2\n```\n\n\n:::\n:::\n", | ||
"supporting": [], | ||
"filters": [ | ||
"rmarkdown/pagebreak.lua" | ||
], | ||
"includes": {}, | ||
"engineDependencies": {}, | ||
"preserve": {}, | ||
"postProcess": 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
{"mastering-graphics.qmd":[],"bibliografia.qmd":[],"estadistica-correlacional.qmd":[],"redes-neuronales.qmd":[],"intro.qmd":["knuth84"],"analisis-estadistico.qmd":[],"metodos-clasificacion.qmd":[],"references.qmd":[],"estadistica-no-parametrica.qmd":[],"diseno-validacion-encuestas.qmd":[],"programacion.qmd":[],"estadistica-bayesiana.qmd":[],"estadistica-univariante.qmd":[],"analisis-multivariante.qmd":[],"index.qmd":[],"introduccion-a-spss.qmd":[],"analisis-series-tiempo.qmd":[],"summary.qmd":[]} |
Oops, something went wrong.