brentthorne | b2fdd57 | 2019-01-04 23:32:17 -0500 | [diff] [blame] | 1 | --- |
brentthorne | 16e1840 | 2019-01-05 10:48:08 -0500 | [diff] [blame] | 2 | #----ESSENTIALS----# |
| 3 | title: 'Using `posterdown` to generate reproducible conference posters via RMarkdown > Knitr > Markdown > Pandoc > Latex > PDF workflow' |
| 4 | author: "Author One^1^ Author Two^2^" |
brentthorne | 1425d47 | 2019-01-07 09:56:42 -0500 | [diff] [blame^] | 5 | affiliation: "^1^Department of Poster Layouts, University of Markdown; ^2^Deparment of Another Institution, Institution University" |
brentthorne | b2fdd57 | 2019-01-04 23:32:17 -0500 | [diff] [blame] | 6 | |
brentthorne | 16e1840 | 2019-01-05 10:48:08 -0500 | [diff] [blame] | 7 | #----FONT STYLE----# |
| 8 | font_size: "30pt" #sets '\normalsize' (sizes of the title and sections headings will adjust based on it) |
| 9 | font_family: "courier" # choose from typical latex fonts (example: "palatino") |
brentthorne | b2fdd57 | 2019-01-04 23:32:17 -0500 | [diff] [blame] | 10 | |
brentthorne | 16e1840 | 2019-01-05 10:48:08 -0500 | [diff] [blame] | 11 | #----COLOURS----# |
| 12 | title_bgcol: "000000" #Hex colour for background of poster title section (default is blue) |
| 13 | poster_bgcol: "white" #colour of the poster main background |
| 14 | title_textcol: "red" #colour of title text |
brentthorne | b2fdd57 | 2019-01-04 23:32:17 -0500 | [diff] [blame] | 15 | header_textcol: "red" #colour of the poster header titles |
brentthorne | 16e1840 | 2019-01-05 10:48:08 -0500 | [diff] [blame] | 16 | cite_col: "green" #colour of ciation elements |
| 17 | url_col: "cyan" #colour of url links |
| 18 | link_col: "cyan" #colour of other links within the poster |
| 19 | columnline_col: "blue" #colour |
brentthorne | b2fdd57 | 2019-01-04 23:32:17 -0500 | [diff] [blame] | 20 | |
brentthorne | 16e1840 | 2019-01-05 10:48:08 -0500 | [diff] [blame] | 21 | #----POSTER SIZE & COLUMN NUMBERS----# |
brentthorne | b2fdd57 | 2019-01-04 23:32:17 -0500 | [diff] [blame] | 22 | poster_height: "38in" # height in inches of poster |
| 23 | poster_width: "45in" # width in inches of poster |
| 24 | column_numbers: 3 # Number of columns that the poster has |
| 25 | |
brentthorne | 16e1840 | 2019-01-05 10:48:08 -0500 | [diff] [blame] | 26 | #----OTHER----# |
brentthorne | b2fdd57 | 2019-01-04 23:32:17 -0500 | [diff] [blame] | 27 | bibliography: MyLibrary # name of the .bib file used for referencing |
brentthorne | 16e1840 | 2019-01-05 10:48:08 -0500 | [diff] [blame] | 28 | output: posterdown::posterdown_pdf |
brentthorne | b2fdd57 | 2019-01-04 23:32:17 -0500 | [diff] [blame] | 29 | --- |
| 30 | |
| 31 | ```{r, include=FALSE} |
| 32 | knitr::opts_chunk$set(echo = FALSE, results = 'asis',fig.height = 3.5, fig.width = 4.5, out.width = "100%", warning = FALSE, fig.align = 'center', message = FALSE, dev='cairo_pdf') |
| 33 | ``` |
| 34 | |
brentthorne | 16e1840 | 2019-01-05 10:48:08 -0500 | [diff] [blame] | 35 | <!-- |
| 36 | Bellow you will find typical RMarkdown syntax which should fill in the columns for the poster from top to bottom left to right. The more information you have the more will be filled. Please let me know if you have feedback at brentthorne18@gmail.com or at github.com/brentthorne/posterdown |
| 37 | |
| 38 | ENJOY! XD |
| 39 | --> |
| 40 | |
brentthorne | b2fdd57 | 2019-01-04 23:32:17 -0500 | [diff] [blame] | 41 | # Introduction |
| 42 | |
| 43 | Welcome to `posterdown` ! This is my attempt to provide a semi-smooth workflow for those who wish to take their `RMarkdown` skills to the conference world. Many creature comforts from `RMarkdown` are available in this package such as `Markdown` section notation, figure captioning, and even citations like this one [@holden_identifying_2012] The rest of this example poster will show how you can insert typical conference poster features into your own document. |
| 44 | |
| 45 | # Study Site |
| 46 | |
| 47 | Here is a map made to show the study site using `ggplot2`, `ggspatial`, and `sf`. Lorem ipsum dolor sit amet, [@middleton_geological_nodate] consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Phasellus vestibulum lorem sed risus ultricies tristique nulla. Mauris vitae ultricies leo integer malesuada nunc vel risus commodo. Suspendisse potenti nullam ac tortor vitae. Enim nunc faucibus a pellentesque sit amet porttitor eget. \vspace{15mm} |
| 48 | |
| 49 | ```{r, fig.width=4.5, out.width="80%", fig.cap='This is a map of Canada, the ggspatial package is great for GIS folks in R!', cache=TRUE} |
| 50 | library(ggplot2) |
| 51 | library(ggspatial) |
| 52 | library(ggthemes) |
| 53 | library(sf) |
| 54 | |
| 55 | canada <- read_sf("data/Canada.geojson") |
| 56 | |
| 57 | |
| 58 | ggplot() + |
| 59 | ggspatial::layer_spatial(canada, fill = "grey") + |
| 60 | ggspatial::annotation_north_arrow(location = "br", which_north = "true", style = north_arrow_nautical()) + |
| 61 | coord_sf() + |
| 62 | theme_solarized() + |
| 63 | NULL |
| 64 | |
| 65 | ``` |
| 66 | |
| 67 | |
| 68 | # Objectives |
| 69 | |
| 70 | \large |
| 71 | |
| 72 | 1. Easy to use reproducible poster design. |
| 73 | 2. Integration with `RMarkdown`. |
| 74 | 3. Easy transition from `posterdown` to `thesisdown` or `rticles` |
| 75 | |
| 76 | \small |
| 77 | |
| 78 | # Methods |
| 79 | |
| 80 | This package uses the same workflow approach as the `RMarkdown` you know and love. Basically it goes from RMarkdown > Knitr > Markdown > Pandoc > Latex > PDF |
| 81 | |
| 82 | # Results |
| 83 | |
| 84 | Usually you want to have a nice table displaying some important results that you have calcualated. In posterdown this is as easy as using the `kable` table formatting you are probably use to as per typical `RMarkdown` formatting. I suggesting checking out the `kableExtra` package and its in depth documentation on customizing these tables found [here](https://haozhu233.github.io/kableExtra/awesome_table_in_pdf.pdf). |
| 85 | |
| 86 | ```{r} |
| 87 | library(kableExtra) |
| 88 | library(ggplot2) |
| 89 | |
| 90 | data("iris") |
| 91 | |
| 92 | kable(iris[1:4,],align = "c", caption = "Tables are a breeze with Kable and Kable extra package!", booktabs = TRUE) %>% |
| 93 | kable_styling(latex_options = "striped",full_width = TRUE, font_size = 25) |
| 94 | |
| 95 | ``` |
| 96 | |
| 97 | \vspace{1in} |
| 98 | |
| 99 | ```{r, out.width='75%', fig.width=4, fig.height=3, fig.cap='A typical plot using ggplot using the classic iris dataset.'} |
| 100 | |
| 101 | library(ggplot2) |
| 102 | library(ggthemes) |
| 103 | |
| 104 | ggplot(data = iris, aes(x = Sepal.Length, y = Sepal.Width, colour = Species)) + |
| 105 | geom_point() + |
| 106 | theme_fivethirtyeight() + |
| 107 | labs(x = "Sepal Length", y = "Sepeal Width") + |
| 108 | NULL |
| 109 | |
| 110 | ``` |
| 111 | |
| 112 | \vspace{1in} |
| 113 | |
| 114 | ```{r, out.width='85%', fig.width=4.5, fig.height=4, fig.cap='Another typical plot using ggplot, this time with a different theme and r code chunk options for fig.width and fig.height.'} |
| 115 | |
| 116 | library(ggplot2) |
| 117 | library(ggthemes) |
| 118 | |
| 119 | ggplot(data = iris, aes(x = Sepal.Length, y = Sepal.Width, colour = Species)) + |
| 120 | geom_point() + |
| 121 | theme_hc() + |
| 122 | labs(x = "Sepal Length", y = "Sepeal Width") + |
| 123 | NULL |
| 124 | |
| 125 | ``` |
| 126 | |
| 127 | \vspace{1in} |
| 128 | |
| 129 | ```{r, out.width='80%', fig.width=4.5, fig.align='center', echo=TRUE, fig.height=5, fig.cap='Another figure showing how base R plots might look on this poster!'} |
| 130 | |
| 131 | # Here is some code for people |
| 132 | # to look at and be in awe of!!!! |
| 133 | library(ggplot2) |
| 134 | library(ggthemes) |
| 135 | |
| 136 | ggplot(data=iris, |
| 137 | aes(x = Sepal.Width, |
| 138 | y = Sepal.Length, |
| 139 | colour = Species)) + |
| 140 | geom_point() + |
| 141 | theme_stata() + |
| 142 | NULL |
| 143 | |
| 144 | ``` |
| 145 | |
| 146 | |
| 147 | # Next Steps |
| 148 | |
| 149 | There is still **A LOT** of work to do on this package which include (but are note limited to): |
| 150 | |
brentthorne | 16e1840 | 2019-01-05 10:48:08 -0500 | [diff] [blame] | 151 | - Better softcoding for front end user options in YAML |
brentthorne | b2fdd57 | 2019-01-04 23:32:17 -0500 | [diff] [blame] | 152 | - Images in the title section for logo placement which is a common attribut to posters as far as I have come to know. |
| 153 | - Figure out compatiability with `natbib` which wasn't working during the initial set up. |
| 154 | - MUCH BETTER PACKAGE DOCUMENTATION. For example, there is nothing in the README... |
| 155 | - Include References section only if initiated by the user like in RMarkdown. |
| 156 | |
brentthorne | 16e1840 | 2019-01-05 10:48:08 -0500 | [diff] [blame] | 157 | <!--- Here you can set the size of the citation text --> |
brentthorne | b2fdd57 | 2019-01-04 23:32:17 -0500 | [diff] [blame] | 158 | \small |