Centralize library loading in 00_paths.R to suppress dplyr startup messages
This commit is contained in:
@@ -2,7 +2,15 @@
|
||||
# Central path constants and config. Source this at the top of every script.
|
||||
# All paths are relative to the project root.
|
||||
|
||||
dotenv::load_dot_env(".env")
|
||||
suppressPackageStartupMessages({
|
||||
library(dotenv)
|
||||
library(tibble)
|
||||
library(readr)
|
||||
library(tidyr)
|
||||
library(dplyr)
|
||||
})
|
||||
|
||||
load_dot_env(".env")
|
||||
euro_to_dollar_conversion_ratio <- as.numeric(Sys.getenv("euro_to_dollar_conversion_ratio"))
|
||||
input_cols <- as.integer(Sys.getenv("input_cols"))
|
||||
|
||||
|
||||
@@ -5,8 +5,6 @@
|
||||
|
||||
source("scripts/00_paths.R")
|
||||
|
||||
library(tibble)
|
||||
library(readr)
|
||||
|
||||
df_income <- tribble(
|
||||
~id, ~category, ~denomination, ~jan, ~feb, ~mar, ~apr, ~may, ~jun,
|
||||
|
||||
@@ -3,7 +3,6 @@
|
||||
|
||||
source("scripts/00_paths.R")
|
||||
|
||||
library(readr)
|
||||
|
||||
df_income <- read_csv(income_raw, show_col_types = FALSE)
|
||||
df_population <- read_csv(population_raw, show_col_types = FALSE)
|
||||
|
||||
@@ -4,8 +4,6 @@
|
||||
|
||||
source("scripts/00_paths.R")
|
||||
|
||||
library(readr)
|
||||
library(dplyr)
|
||||
|
||||
df <- read_csv(income_raw, show_col_types = FALSE)
|
||||
|
||||
|
||||
@@ -3,8 +3,6 @@
|
||||
|
||||
source("scripts/00_paths.R")
|
||||
|
||||
library(readr)
|
||||
library(tidyr)
|
||||
|
||||
df <- read_csv(income_usd_wide, show_col_types = FALSE)
|
||||
|
||||
|
||||
@@ -4,9 +4,6 @@
|
||||
|
||||
source("scripts/00_paths.R")
|
||||
|
||||
library(readr)
|
||||
library(tidyr)
|
||||
library(dplyr)
|
||||
|
||||
df <- read_csv(population_raw, show_col_types = FALSE)
|
||||
|
||||
|
||||
@@ -3,8 +3,6 @@
|
||||
|
||||
source("scripts/00_paths.R")
|
||||
|
||||
library(readr)
|
||||
library(dplyr)
|
||||
|
||||
df_income <- read_csv(income_usd, show_col_types = FALSE)
|
||||
df_pop <- read_csv(population_full, show_col_types = FALSE) |>
|
||||
|
||||
@@ -3,8 +3,6 @@
|
||||
|
||||
source("scripts/00_paths.R")
|
||||
|
||||
library(readr)
|
||||
library(dplyr)
|
||||
|
||||
df_merged <- read_csv(merged, show_col_types = FALSE)
|
||||
|
||||
|
||||
@@ -3,8 +3,6 @@
|
||||
|
||||
source("scripts/00_paths.R")
|
||||
|
||||
library(readr)
|
||||
library(dplyr)
|
||||
|
||||
df <- read_csv(result, show_col_types = FALSE)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user