Publications by pacha.dev/blog

tabulapdf: Extract Tables from PDF Documents

28.04.2024

Motivation I had to extract multiple tables from PDF files and do some data analysis in R. I found that updating tabulizer (now retired from CRAN) to use a Java version newer than Java 8 (deprecated) was worth it to complete this task. tabulapdf is a reworked version of tabulizer that works with OpenJDK 11 and newer. I wanted to share it here and s...

5842 sym R (8170 sym/23 pcs)

Tetley caffeine meter replication with ggplot2

04.04.2024

Tetley tea boxes feature the following caffeine meter: In R we can replicate this meter using ggplot2. Move the information to a tibble: library(dplyr) caffeine_meter <- tibble( cup = c("Coffee", "Tea", "Green Tea", "Decaf Tea"), caffeine = c(99, 34, 34, 4) ) caffeine_meter # A tibble: 4 × 2 cup caffeine <chr> <dbl> 1 Cof...

965 sym R (1219 sym/7 pcs) 12 img

Canadamaps 0.3.0

23.03.2024

Motivation The creation of Canadamaps is deeply rooted in a journey from adversity to contribution. Following a challenging period marked by the “social explosion” in Chile, which led to multiple casualties, wounded people, the destruction of my neighborhood, along with multiple arson attacks that destroyed subway stations, churches, supermarke...

2376 sym R (3767 sym/8 pcs) 10 img

Introducing cpp11armadillo: R and Armadillo integration using the header-only cpp11 R package

25.01.2024

The goal of cpp11armadillo is to provide a novel approach to use the Armadillo C++ library by using the header-only cpp11 R package and to simplify things for the end-user. The idea is to pass matrices/vectors from R to C++, write pure C++/Armadillo code for the computation, and then export the result back to R with the proper data structures. This...

3358 sym R (575 sym/3 pcs) 2 img

Introducing Capybara: Fast and Memory Efficient Fitting of Linear Models With High-Dimensional Fixed Effects

18.01.2024

About Capybara is a fast and small footprint software that provides efficient functions for demeaning variables before conducting a GLM estimation via Iteratively Weighted Least Squares (IWLS). This technique is particularly useful when estimating linear models with multiple group fixed effects. The software can estimate GLMs from the Exponential F...

2313 sym R (818 sym/3 pcs) 2 img 2 tbl

The Hitchhiker’s Guide to Linear Models is now complete

07.09.2023

The book can be downloaded for free but you will need a Leanpub account, same if you buy it. The Hitchhiker’s Guide to Linear Models is finally complete. It took me a while to finish it but I’m happy with the result. I hope you enjoy it as much as I did writing it. The Github repository contains the code for the book so that the readers can avo...

423 sym 2 img 1 tbl

An R package with Baltagi’s ‘Econometric Analysis of Panel Data’ datasets

27.08.2023

About ‘Econometric Analysis of Panel Data’ (ISBN 978-3-030-53952-8) provides up-to-date coverage of basic panel data techniques, illustrated with real economic applications and datasets. However, importing the original data from the book into R is not straightforward because some of the datasets are available in Microsoft Word format. I provide...

1627 sym R (1271 sym/3 pcs) 2 img

The Hitchhiker’s Guide to Econometrics with Available Code in R

15.08.2023

The book can be downloaded for free but you will need a Leanpub account, same if you buy it. This release corresponds to chapters 1, 3, 4 and 5 of The Hitchhiker’s Guide to Econometrics. The Github repository contains the code for the book so that the readers can avoid copy and paste from the PDF. Don’t panic! Related To leave a comment for t...

708 sym 2 img

The Hitchhiker’s Guide to Econometrics: Based on the famous R programming language

10.08.2023

This release is the first draft for chapters 1 and 2 of The Hitchhiker’s Guide to Econometrics. I would really appreciate some feedback outside my friend’s circle to check. I hope to be writing something useful, a text that you can read after reading Wooldridge’s Econometrics to practice R. Based on the feedback I will edit the other chapters...

838 sym 2 img

Plotting a COVID-19 vaccination map with different projections (with updated versions of canadamaps and tintin)

01.08.2023

R and Shiny Training: If you find this blog to be interesting, please note that I offer personalized and group-based training sessions that may be reserved through Buy me a Coffee. Additionally, I provide training services in the Spanish language and am available to discuss means by which I may contribute to your Shiny project. Motivation I had to...

1934 sym R (2128 sym/5 pcs) 6 img