This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
library(tidyverse) | |
library(magicr) | |
library(arrow) | |
# Download WOE replay data | |
woe_game_replay_file <- mr_download_17lands_file( | |
"WOE", "replay", "premier") | |
# Load WOE replay data | |
woe_game_replay <- arrow::open_csv_dataset( |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
library(tidyverse) | |
library(magicr) | |
library(arrow) | |
# Download WOE replay data | |
woe_game_replay_file <- mr_download_17lands_file( | |
"WOE", "replay", "premier") | |
# Load WOE replay data | |
woe_game_replay <- arrow::open_csv_dataset( |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# To install magicr | |
# pak::pkg_install("joelnitta/magicr") | |
library(tidyverse) | |
library(magicr) | |
# OP: | |
# I'm working on some WOE replay data for Premier Draft and I'm seeing some | |
# stuff I don't understand. On row-index 8541, user plays both "Bakery Raid" and | |
# "Welcome to Sweet Tooth" on turn one, which can't happen. The same happens on |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# To install magicr | |
# pak::pkg_install("joelnitta/magicr") | |
library(tidyverse) | |
library(magicr) | |
library(ggrepel) | |
# Win-rate by rank and set ---- | |
# Define function to calculate win-rate by rank for a particular set |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# List all functions and packages used by R scripts in a project. | |
library(NCmisc) | |
# IMPORTANT: Also load any libraries used by the project | |
# Make list of all functions by package | |
funcs <- | |
list.files(here::here(), pattern ="\\.R$", recursive = TRUE, full.names = TRUE) %>% | |
map(list.functions.in.file) %>% | |
flatten |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
library(rtweet) | |
# Initial authorization setup, only need to do once | |
# auth_setup_default() #nolint | |
# Authorize | |
auth_as("default") | |
# Set user name | |
user_name <- "PUT USER NAME HERE" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
library(rtweet) | |
library(tidyverse) | |
# Initial authorization setup, only need to do once | |
# auth_setup_default() #nolint | |
# Authorize | |
auth_as("default") | |
# Set user name |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
library(tidyverse) | |
library(assertr) | |
# Define custom parsing function | |
#' Parse a single record from the NCBI taxonomy database | |
#' | |
#' The NCBI taxonomy database contains names in the `names.dmp` file. | |
#' A single record (corresponding to one `taxid`) looks like this: | |
#' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/bash | |
# Start docker daemon in background | |
nohup dockerd-rootless.sh --experimental --storage-driver vfs >| dockerd.log 2>&1 & | |
# Save the process ID so we can kill it later | |
echo $! > dockerd.pid | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# SOME DESCRIPTIVE TITLE | |
# Copyright (C) YEAR Free Software Foundation, Inc. | |
# This file is distributed under the same license as the PACKAGE package. | |
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR. | |
# | |
#, fuzzy | |
msgid "" | |
msgstr "" | |
"Project-Id-Version: PACKAGE VERSION\n" | |
"POT-Creation-Date: 2022-08-08 07:55+0000\n" |
NewerOlder