set_db: set up the package settings

Description Usage Arguments Details

View source: R/config.R

Description

set up the package settings

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
set_db(
  json_config_file_name = "config_global_ra.json",
  json_config_path = "secrets",
  json_config_root = "",
  data_provider = c("opta", "inStat", "STATS", "whoScored"),
  database_type = c("localhost", "prod", "prod_backup"),
  feed_collections = c("events", "fixtures", "players", "gameEvents"),
  feats_collections = c("playerKeyPasses"),
  spadl_collections = c("features", "action_values"),
  spadl_config = "spadl_config.json",
  opta_config = "opta_config.json",
  instat_config = "instat_config.json",
  scores_spadl_model_path = "model_spadl_scores.RDS",
  concedes_spadl_model_path = "model_spadl_concedes.RDS",
  scores_atomic_model_path = "model_atomic_scores.RDS",
  concedes_atomic_model_path = "model_atomic_concedes.RDS",
  project_name = "playeraction"
)

Arguments

json_config_file_name, json_config_path, json_config_root

character info needed to access the global config file.

database_type

character type of data-base connection

project_name

character project-name

target_db

character type of database playeraction

collections_provider

character name of collection to connect to from the data_provider family

collections_target

character name of collection to connect to from the target_db family

Details

save the package settings in a top-level environment called .settings. The function is called at loading time with default arguments.


salembsk/playeraction documentation built on Nov. 10, 2020, 8:03 p.m.