MyNixOS website logo
Description

BoardGameGeek's Board Game Data Analysis Tools.

Tools for analysing board game data. Mainly focused on providing an interface for BoardGameGeek's XML API2 through R6 class system objects. More details about the BoardGameGeek's API can be obtained here <https://boardgamegeek.com/wiki/page/BGG_XML_API2>.

bggAnalytics

R package for simple downloading and organisation of board game data using BoardGameGeek's XML API2. Users of R programming language should have no problems extracting their BGG games collection data, or in fact, the information about any games from BGG. This allows for automatisation of the collection exporting task, which has to be done manually on the BGG website.

Installation

The package will be uploaded to CRAN in the future. In the meanwhile, it can be installed using the devtools package.

library(devtools)
install_github("JakubBujnowicz/bggAnalytics")

How To Use?

The package uses R6 classes and data.table package as a backbone for data. Hence usage is heavily leaning on reference, which is quite uncommon for R programming language.

Easiest way to start is to create a bggCollection object for a certain user. For showcase purposes, I'm using my BGG account called Beo_.

library(bggAnalytics)
my_collection <- bggCollection$new(username = "Beo_")
my_collection

Another step would be to fetch some data - everything (from the set of currently supported variables) can be fetched using fetch method.

my_collection$fetch()
# Or
my_collection$fetch(c("name", "yearpublished"))

Method called extend can be used in the same manner to extend object's data slot by given variables.

my_collection$data
# Currently only objectid
my_collection$extend(c("name", "yearpublished"))
my_collection$data

Note that this extension is done by reference, hence no assignment is necessary.

One doesn't have to rely on a given user's collection to download game's data. You can find a game ID by looking at it's BGG hyperlink, e.g. https://boardgamegeek.com/boardgame/167791/terraforming-mars is a link for Terraforming Mars, hence 167791 is it's ID.

games <- bggGames$new(ids = 167791)
games$extend()
games$data

Naturally, multiple IDs may be supplied to bggGames object. One can always extract IDs from a collection by my_collection$ids.

Metadata

Version

0.2.1

License

Unknown

Platforms (75)

    Darwin
    FreeBSD
    Genode
    GHCJS
    Linux
    MMIXware
    NetBSD
    none
    OpenBSD
    Redox
    Solaris
    WASI
    Windows
Show all
  • aarch64-darwin
  • aarch64-genode
  • aarch64-linux
  • aarch64-netbsd
  • aarch64-none
  • aarch64_be-none
  • arm-none
  • armv5tel-linux
  • armv6l-linux
  • armv6l-netbsd
  • armv6l-none
  • armv7a-darwin
  • armv7a-linux
  • armv7a-netbsd
  • armv7l-linux
  • armv7l-netbsd
  • avr-none
  • i686-cygwin
  • i686-darwin
  • i686-freebsd
  • i686-genode
  • i686-linux
  • i686-netbsd
  • i686-none
  • i686-openbsd
  • i686-windows
  • javascript-ghcjs
  • loongarch64-linux
  • m68k-linux
  • m68k-netbsd
  • m68k-none
  • microblaze-linux
  • microblaze-none
  • microblazeel-linux
  • microblazeel-none
  • mips-linux
  • mips-none
  • mips64-linux
  • mips64-none
  • mips64el-linux
  • mipsel-linux
  • mipsel-netbsd
  • mmix-mmixware
  • msp430-none
  • or1k-none
  • powerpc-netbsd
  • powerpc-none
  • powerpc64-linux
  • powerpc64le-linux
  • powerpcle-none
  • riscv32-linux
  • riscv32-netbsd
  • riscv32-none
  • riscv64-linux
  • riscv64-netbsd
  • riscv64-none
  • rx-none
  • s390-linux
  • s390-none
  • s390x-linux
  • s390x-none
  • vc4-none
  • wasm32-wasi
  • wasm64-wasi
  • x86_64-cygwin
  • x86_64-darwin
  • x86_64-freebsd
  • x86_64-genode
  • x86_64-linux
  • x86_64-netbsd
  • x86_64-none
  • x86_64-openbsd
  • x86_64-redox
  • x86_64-solaris
  • x86_64-windows