knitr::opts_chunk$set( collapse = TRUE, comment = "#>", fig.path = "man/figures/README-", fig.align = "center", message = FALSE, warning = FALSE )
https://nexushub.co/ provides and API to data mine several prices of in game items of the video game World of Warcraft Classic. The following tool simplifies R users to import the data or loop over several items. Please be reminded that all data is collected by the nexushub team and their development page can be visited here.
devtools::install_github("gstephan30/nexminer")
The following examples show how to import price trends of Black Lotus or Rugged Hide on the EU server Patchwerk Faction Horde:
library(nexminer) library(patchwork) server <- "patchwerk" fraction <- "horde" rh_raw <- import_item("rugged hide", server, fraction) rh_clean <- clean_json(rh_raw) p1 <- smooth_item(rh_clean) p2 <- lm_item_wday(rh_clean) p1 / p2
bl_raw <- import_item("Black LOTus", server, fraction) bl_clean <- clean_json(bl_raw) p3 <- smooth_item(bl_clean) p4 <- lm_item_wday(bl_clean) p3 / p4
Or just loop over multiple items:
library(dplyr) library(purrr) flasks <- c("Flask of the Titans", "Flask of Distilled Wisdom", "Flask of Supreme Power", "Flask of Chromatic Resistance", "Flask of Petrification") flasks_df <- flasks %>% map_df(function (x) import_item(x, server, fraction) %>% clean_json() ) # count of times where flasks are captured flasks_df %>% count(item, sort = TRUE) flasks_df %>% group_split(item) %>% map(smooth_item) %>% wrap_plots(ncol = 1)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.