How ralmario/rawr_getresults works
Project type and purpose
• This is a small, single-script data-processing utility written in R.
• Purpose: Read an Excel file of video game titles, call the Rawg.io REST API for each title’s release year, then write results back to a new Excel file.
File structure
• Top-level files only:
• rawr.R – the main R script containing the getResults() function and all logic.
• README.md – describes usage, inputs/outputs, dependencies.
• .gitattributes – Git config (no bearing on runtime architecture).
• No frontend, no services inside this repo beyond the R script.
• Key external dependency: Rawg.io HTTP API.
• Key libraries: openxlsx (Excel I/O), jsonlite (JSON parsing), dplyr (data manipulation).
README for additional insights
• Input: a .xlsx file with column “Game Name.”
• Output: a .xlsx file augmented with “Year Released.”
• Workflow is linear: read → transform → write.
• No multi-stage compilation or long-running server processes.
a. Main components:
1. Client environment (RStudio or R console)
2. rawr.R script
3. Input spreadsheet file
4. Rawg.io external REST API
5. Output spreadsheet file
6. R packages (openxlsx, jsonlite, dplyr) as library modules
b. Relationships and interactions:
• The user invokes getResults() in the R environment.
• rawr.R loads the input spreadsheet via openxlsx.
• For each game name, rawr.R sends HTTP GET requests to Rawg.io API (jsonlite for parsing).
• rawr.R processes API responses with dplyr (extracts release year).
• rawr.R writes the new column back to an output spreadsheet via openxlsx.
c. Architectural patterns and design principles:
• Simple linear ETL (Extract → Transform → Load) pipeline.
• Single-module script; no microservices or multi-tier layering.
• Separation of concerns:
• Data I/O layer (openxlsx)
• API integration layer (jsonlite + HTTP requests)
• Data processing layer (dplyr)
d. Relevant technologies/frameworks:
• R (language/runtime)
• openxlsx (Excel read/write)
• jsonlite (JSON serialization)
• dplyr (data manipulation)
• Rawg.io REST API (external service)