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
auth_50 %>% | |
ggplot(aes(avg_cit, n_papers, color = avg_age_of_papers))+ | |
geom_vline(xintercept = 0, size = 2, color = "#04444499")+ | |
geom_point(size = 2)+ | |
geom_text( | |
aes(label = author_abbr, size = n_papers), | |
hjust = c(-.1, 1.1) %>% rep(25), | |
vjust = c(-.05, 1.05) %>% rep(25), | |
fontface = 2, | |
alpha = .75 |
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
#=============================================================================== | |
# 2023-12-21 -- misc | |
# convert pdf to png | |
# Ilya Kashnitsky, ilya.kashnitsky@gmail.com, @ikashnitsky | |
#=============================================================================== | |
#' @description A function to convert all PDFs in a directory into PNGs | |
#' @param dir_pdfs character. A character string with a path to the directory containing PDFs to convert | |
#' @param output_dir character. An optional parameter to specify the output directory for the converted PNGs. Defaults to `"/png"`, which creates a sub-directory `png` in the specified above `dir_pdfs` directory. Can be any location on the machine, one useful place may be something with all the temporary stuff like `"~/Downloads"`. Important: don't leave trailing slashes in the parameters. |
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
#=============================================================================== | |
# 2023-11-06 -- 30DayMapChallenge | |
# ASIA -- restaurants in Denmark | |
# Ilya Kashnitsky, ilya.kashnitsky@gmail.com, @ikashnitsky.phd | |
#=============================================================================== | |
library(tidyverse) | |
library(magrittr) | |
library(osmdata) | |
library(eurostat) |
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
#=============================================================================== | |
# 2021-01-07 -- twitter | |
# Visualize Publons country data | |
# https://publons.com/country | |
# Ilya Kashnitsky, ilya.kashnitsky@gmail.com | |
#=============================================================================== | |
library(tidyverse) | |
library(magrittr) | |
library(sf) |
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
#=============================================================================== | |
# 2023-04-12 -- SMD lightning talk | |
# Usecase of SMD | |
# Ilya Kashnitsky, ilya.kashnitsky@gmail.com, @ikashnitsky | |
#=============================================================================== | |
library(tidyverse) | |
library(magrittr) | |
library(prismatic) | |
library(janitor) |
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
#=============================================================================== | |
# 2020-06-19 -- twitter | |
# improve plot | |
# Ilya Kashnitsky, ilya.kashnitsky@gmail.com | |
#=============================================================================== | |
# the challenge | |
# https://community.storytellingwithdata.com/exercises/one-little-changeand-a-redesign | |
library(tidyverse) |
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
#=============================================================================== | |
# 2023-01-03 -- ik-q | |
# My custom ggplot2 theme | |
# Ilya Kashnitsky, ilya.kashnitsky@gmail.com, @ikashnitsky | |
#=============================================================================== | |
library(ggplot2) | |
theme_ik <- function( | |
base_size = 12, |
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
#=============================================================================== | |
# 2020-04-08 -- twitter upd 2023-01-01 ik-q | |
# Showcase the map hack -- use border lines instead of polygon outlines | |
# https://twitter.com/ikashnitsky/status/1247875600305598464 | |
# https://ikashnitsky.github.io/2023/map-borders | |
# Ilya Kashnitsky, ilya.kashnitsky@gmail.com | |
#=============================================================================== | |
library(tidyverse) | |
library(sf) |
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
#=============================================================================== | |
# 2022-12-25 -- ik-q | |
# World cups -- was Qatar that exceptional? | |
# Ilya Kashnitsky, ilya.kashnitsky@gmail.com, @ikashnitsky | |
#=============================================================================== | |
library(tidyverse) | |
library(magrittr) | |
library(wdman) | |
library(RSelenium) |
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
#=============================================================================== | |
# 2022-12-04 -- misc | |
# get oddsportal data | |
# Ilya Kashnitsky, ilya.kashnitsky@gmail.com, @ikashnitsky | |
#=============================================================================== | |
library(tidyverse) | |
library(magrittr) | |
library(ggrepel) | |
library(sysfonts) |
NewerOlder