View puppeteer-fetch-and-render-docker.js
// puppeteer-fetch-and-render-docker.js | |
// Fetch and render using an specific google chrome version | |
// We'll use appropiate zenika/alpine-chrome docker image. More information: https://github.com/Zenika/alpine-chrome | |
// Run: | |
// $ docker run -it --mount src="$(pwd)",target=/myproject,type=bind zenika/alpine-chrome:76-with-puppeteer /bin/sh | |
// /usr/src/app# cp /myproject/puppeteer-fetch-and-render.js . | |
// /usr/src/app# node puppeteer-fetch-and-render.js | |
// /usr/src/app# cp screenshot.png /myproject | |
// /usr/src/app# exit |
View conflicted.R
if(!require(tidyverse)) install.packages("tidyverse") | |
if(!require(conflicted)) install.packages("conflicted") | |
tidyverse_update() | |
library(tidyverse) | |
library(MASS) | |
library(conflicted) | |
conflict_scout() | |
Cars93 %>% dplyr::select(Origin) |
View trello-to-pdf.Rmd
--- | |
title: "Trello to PDF" | |
author: "jrosell" | |
date: "2020-07-28" | |
output: pdf_document | |
--- | |
## R Markdown | |
This is an R Markdown document. It gets Trello cards and its attachments from specific list on a public board and build a PDF document from it. |
View comunicar.R
if(!require(tidyverse)) install.packages("tidyverse") | |
if(!require(patchwork)) install.packages("patchwork") | |
library(patchwork) | |
library(tidyverse) | |
library(lubridate) | |
# Añadir anotaciones | |
ggplot(mpg, aes(displ, hwy)) + | |
geom_point(aes(color = class)) + | |
geom_smooth(se = FALSE) + labs( |
View eurostat.Rmd
--- | |
title: "Impuestos y sueldos por país en Europa" | |
author: "Jordi Rosell" | |
date: "2020-06-08" | |
output: | |
html_document: | |
df_print: paged | |
--- | |
```{r setup, include=FALSE} |
View procesar.R
if(!require(tidyverse)) install.packages("tidyverse") | |
if(!require(patchwork)) install.packages("patchwork") | |
if(!require(nycflights13)) install.packages('nycflights13') | |
if(!require(tidymodels)) install.packages("tidymodels") | |
if(!require(modelr)) install.packages("modelr") | |
library(tidymodels) | |
library(nycflights13) | |
library(patchwork) | |
library(tidyverse) | |
library(lubridate) |
View ordenar.R
if(!require(tidyverse)) install.packages("tidyverse") | |
library(tidyverse) | |
# Alargar filas fundiendo columnas | |
relig_income | |
longer <- relig_income %>% pivot_longer(-religion, names_to = "income", values_to = "count") %>% print() | |
# Ensanchar columnas proyectando filas | |
us_rent_income | |
wider <- us_rent_income %>% pivot_wider(names_from = variable, values_from = c(estimate, moe)) %>% print() |
View importar.R
if(!require(tidyverse)) install.packages("tidyverse") | |
if(!require(feather)) install.packages("feather") | |
if(!require(RSQLite)) install.packages("RSQLite") | |
library(tidyverse) | |
library(hms) | |
library(haven) | |
library(feather) | |
library(readxl) | |
library(DBI) |
View magento_api.php
<?php | |
class Runner { | |
public $baseURL; | |
public $username; | |
public $password; | |
public $token_string; | |
function __construct() { | |
$this->baseURL = "https://domain.com/index.php"; | |
$this->username = "magento_api"; |
View explorar.R
if(!require(tidyverse)) install.packages("tidyverse") | |
if(!require(patchwork)) install.packages("patchwork") | |
if(!require(nycflights13)) install.packages('nycflights13') | |
if(!require(tidymodels)) install.packages("tidymodels") | |
if(!require(modelr)) install.packages("modelr") | |
library(tidymodels) | |
library(modelr) | |
library(tidymodels) | |
library(patchwork) | |
library(tidyverse) |
NewerOlder