-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathREADME.Rmd
51 lines (38 loc) · 1.79 KB
/
README.Rmd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
---
output: github_document
---
```{r, include = FALSE}
knitr::opts_chunk$set(
comment = "#>"
)
```
<!-- README.md is generated from README.Rmd. Please edit that file -->
# headliner <img src="man/figures/logo.png" align="right" alt="" width="120" />
<!-- badges: start -->
[](https://cran.r-project.org/package=headliner/)
[](https://cran.r-project.org/package=headliner)
[](https://app.codecov.io/gh/rjake/headliner/)
[](https://github.com/rjake/headliner/actions/)
<!-- [](https://cran.r-project.org/package=headliner) -->
<!-- badges: end -->
The goal of `headliner` is to translate facts into insights. Given two values, `headliner` generates building blocks for creating dynamic text. These talking points can be combined using using `glue` syntax to add informative titles to plots, section headers or other text in a report.
## Installation
You can install the dev version of `headliner` from [github](https://github.com/rjake/headliner) with:
``` r
devtools::install_github("rjake/headliner")
```
Let's look at some of the talking points for the difference between 5 and 7:
```{r}
library(headliner)
compare_values(5, 7) |> # returns a list
view_list() # show as a data frame
```
We can string the talking points together like this:
```{r}
headline(
x = 5,
y = 7,
headline = "There was {article_delta_p}% {trend} ({orig_values})"
)
```
See [here](https://rjake.github.io/headliner/articles/intro.html) for a longer introduction.