Three or more hashtags.
#[^#]+#[^#]+#
Long hashtags (15+ characters): #hashtagpunchline
### Heather Piwowar | |
# Modifications to add confidence intervals added by Heather Piwowar | |
# Based on dotchart2{Hmisc} | |
dotchart2.CIs = | |
function (data, labels, groups = NULL, gdata = NA, horizontal = TRUE, | |
pch = 16, xlab = "", ylab = "", auxdata, auxgdata = NULL, | |
auxtitle, lty = if (.R.) 1 else 2, lines = TRUE, dotsize = 0.8, | |
cex = par("cex"), cex.labels = cex, cex.group.labels = cex.labels * | |
1.25, sort. = TRUE, add = FALSE, dotfont = par("font"), |
{ | |
"word_separators": "/\\()\"'-:,;<>~!@#$%^&*|+=[]{}`~?" | |
} |
##Simply annoying Tweets
Annoyingly extended words (4+ of the same letter in a phrase): OOOOHHHHMMMMYYYYGGGGOOOODDDD
([a-z])/1{4}
Tweet w/ just a single hashtag: #omgthissucks
^ *#[^ ]+$
example.md: example.Rmd | |
./knit | |
example.ipynb: example.md | |
notedown example.md | sed 's/%%r/%%R/' > example.ipynb |
# Helper functions that allow string arguments for dplyr's data modification functions like arrange, select etc. | |
# Author: Sebastian Kranz | |
# Examples are below | |
#' Modified version of dplyr's filter that uses string arguments | |
#' @export | |
s_filter = function(.data, ...) { | |
eval.string.dplyr(.data,"filter", ...) | |
} |
all: example.ipynb example.html | |
example.md: example.Rmd | |
./knit | |
example.ipynb: example.md | |
notedown example.md | sed '/%%r/d' > example.ipynb | |
example.html: example.Rmd | |
R -e "knitr::knit2html('example.Rmd')" |
# Slopegraphs in matplotlib | |
# Trey Causey (@treycausey) | |
# Problems arise when equal values occur | |
# within the same time unit | |
import matplotlib.pyplot as plt | |
import numpy as np | |
import pandas as pd | |
units = ['A', 'B', 'C', 'D'] |
#' A function to create caterpillar plots from rstan's stanfit objects | |
#' | |
#' @param obj a \code{stanfit} object | |
#' @param pars character string, vector, or regular expression of paramater | |
#' labels that you would like to plot as declared in \code{model_code} from the | |
#' \code{\link{stan}} call. | |
#' @param pars_labels vector of parameter labels. Important: they must be in | |
#' the same order as in the \code{stanfit} object when \code{as.data.frame(obj)} | |
#' is called. | |
#' @param hpd logical. If \code{TRUE} then the 90% and 95% highest probability |