Skip to content

Commit

Permalink
Removed captioner
Browse files Browse the repository at this point in the history
  • Loading branch information
royfrancis committed Dec 29, 2023
1 parent d883919 commit 58ced81
Show file tree
Hide file tree
Showing 21 changed files with 37,180 additions and 686 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ on:
jobs:
linux:
name: ubuntu
runs-on: "ubuntu-20.04"
runs-on: latest
strategy:
fail-fast: false
matrix:
Expand Down
3 changes: 1 addition & 2 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Package: minty
Type: Package
Title: Rmarkdown templates for report and slides
Version: 1.2.4
Version: 1.3
Author: Roy Francis
Authors@R:
person(given = "Roy",
Expand All @@ -15,7 +15,6 @@ Depends:
R(>= 3.5.0)
Suggests:
bookdown,
captioner,
markdown,
knitr,
rmarkdown,
Expand Down
5 changes: 5 additions & 0 deletions NEWS
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
minty 1.3
=============
- 29-Dec-2023
- captioner removed

minty 1.2.4
=============
- 27-Mar-2023
Expand Down
5 changes: 5 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
# minty 1.3

- 29-Dec-2023
- captioner removed

# minty 1.2.4

- 27-Mar-2023
Expand Down
4 changes: 1 addition & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,8 @@

An R package with R Markdown templates for reports/documentation and xaringan slides. For preview, installation and usage guide, go to [https://royfrancis.github.io/minty/](https://royfrancis.github.io/minty/).

:exclamation: For quarto template, see [https://github.com/royfrancis/folium](https://github.com/royfrancis/folium).

Credit to <span><a href="https://www.freepik.com"><img src="man/figures/freepik.png" style="height:20px;vertical-align:middle;"></a></span> and <span><a href="https://www.flaticon.com/"><img src="man/figures/flaticon.png" style="height:15px;vertical-align:middle;"></a></span> for illustrations/graphics.

---

**2023** • Roy Francis
**2024** • Roy Francis
2 changes: 1 addition & 1 deletion docs/404.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/LICENSE-text.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions docs/authors.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 2 additions & 3 deletions docs/index.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

20,126 changes: 19,699 additions & 427 deletions docs/nbis-report-demo.html

Large diffs are not rendered by default.

96 changes: 45 additions & 51 deletions docs/nbis-report.html

Large diffs are not rendered by default.

16,894 changes: 16,762 additions & 132 deletions docs/nbis-slide-demo.html

Large diffs are not rendered by default.

651 changes: 644 additions & 7 deletions docs/nbis-slide.html

Large diffs are not rendered by default.

7 changes: 6 additions & 1 deletion docs/news/index.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions docs/pkgdown.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
pandoc: 2.19.2
pandoc: 3.1.3
pkgdown: 2.0.7
pkgdown_sha: ~
articles: {}
last_built: 2023-03-29T19:09Z
last_built: 2023-12-29T15:29Z
urls:
reference: https://github.com/royfrancis/minty/reference
article: https://github.com/royfrancis/minty/articles
Expand Down
2 changes: 1 addition & 1 deletion docs/reference/index.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

12 changes: 0 additions & 12 deletions docs/sitemap.xml
Original file line number Diff line number Diff line change
Expand Up @@ -12,18 +12,6 @@
<url>
<loc>https://github.com/royfrancis/minty/index.html</loc>
</url>
<url>
<loc>https://github.com/royfrancis/minty/nbis-report-demo.html</loc>
</url>
<url>
<loc>https://github.com/royfrancis/minty/nbis-report.html</loc>
</url>
<url>
<loc>https://github.com/royfrancis/minty/nbis-slide-demo.html</loc>
</url>
<url>
<loc>https://github.com/royfrancis/minty/nbis-slide.html</loc>
</url>
<url>
<loc>https://github.com/royfrancis/minty/news/index.html</loc>
</url>
Expand Down
4 changes: 1 addition & 3 deletions index.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,6 @@

An R package with R Markdown templates for reports/documentation and slides.

:exclamation: For quarto template, see [https://github.com/royfrancis/minty-quarto-website](https://github.com/royfrancis/minty-quarto-website).

## Templates

### nbis-report
Expand Down Expand Up @@ -35,7 +33,7 @@ remotes::install_github("royfrancis/minty")
No dependency packages are required to create the template. But the following dependencies are required to render the Rmd to HTML.

```
install.packages(c("bookdown","captioner","knitr","markdown","rmarkdown","xaringan"),repos="https://cloud.r-project.org/")
install.packages(c("bookdown","knitr","markdown","rmarkdown","xaringan"),repos="https://cloud.r-project.org/")
```

The standard templates are to be used for preparing your own material.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,12 @@
# load libraries
library(knitr) # runs pandoc
library(bookdown) # for markdown
library(captioner) # for table and figure captions
# fontawesome dependency
#fa <- rmarkdown::html_dependency_font_awesome()
#fa$attachment <- "fonts/fontawesome-webfont.ttf"
#htmltools::tagList(fa)
# prepare captions
tc <- captioner::captioner(prefix="<b>Tab. </b>")
fc <- captioner::captioner(prefix="<b>Fig. </b>")
# turn off terminal colors
options(crayon.enabled = FALSE)
Expand Down
26 changes: 0 additions & 26 deletions inst/rmarkdown/templates/nbis-report-demo/skeleton/skeleton.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -483,8 +483,6 @@ $\begin{eqnarray} P(|X-\mu| > k) & = & P(|X-\mu|^2 > k^2)\\ & \leq & \frac{\math

View of the data using paged tables. This is the default output for RMarkdown.

`r tc(name="table_paged",caption="_Table using paged tibble._")`

```{r}
iris[1:15,]
```
Expand All @@ -501,8 +499,6 @@ knitr::kable(head(iris), 'html')

More advanced table using [`kableExtra`](https://cran.r-project.org/web/packages/kableExtra/vignettes/awesome_table_in_html.html) and [`formattable`](https://cran.r-project.org/web/packages/formattable/vignettes/formattable-data-frame.html).

`r tc(name="table_kableextra",caption="_Table using kableextra._")`

```{r}
iris[c(1:4,51:53,105:108),] %>%
mutate(Sepal.Length=color_bar("lightsteelblue")(Sepal.Length)) %>%
Expand All @@ -519,8 +515,6 @@ More advanced table using [`kableExtra`](https://cran.r-project.org/web/packages

Interactive table using R package [`DT`](https://rstudio.github.io/DT/).

`r tc(name="table_datatable",caption="_Table using datatable._")`

```{r}
iris %>%
slice(1:15) %>%
Expand All @@ -541,8 +535,6 @@ legend(x=7,y=4.47,legend=c("setosa","versicolor","virginica"),
col=c("coral","steelblue","forestgreen"),pch=19)}
```

`r fc(name="static_base",caption="_Static plot using base plot._")`

## ggplot2

R package [`ggplot2`](http://ggplot2.org/) is one of the most versatile and complete plotting solutions.
Expand All @@ -555,8 +547,6 @@ iris %>%
theme_report()
```

`r fc(name="static_ggplot",caption="_Static plot using ggplot2._")`

# Interactive plots

## highcharter
Expand All @@ -575,8 +565,6 @@ h <- iris %>%
htmltools::tagList(list(h))
```

`r fc(name="interactive_highcharter",caption="_Interactive scatterplot using highcharter._")`

## plotly

R package [`plotly`](https://plot.ly/r/) provides R binding around javascript plotting library [`plotly`](https://plot.ly).
Expand All @@ -588,8 +576,6 @@ p <- iris %>%
p
```

`r fc(name="interactive_plotly",caption="_Interactive scatterplot using plotly._")`

## ggplotly

`plotly` also has a function called `ggplotly` which converts a static ggplot2 object into an interactive plot.
Expand All @@ -604,8 +590,6 @@ p <- iris %>%
ggplotly(p,width=500,height=400)
```

`r fc(name="interactive_ggplotly",caption="_Interactive scatterplot using ggplotly._")`

## ggiraph

`ggiraph` is also an R package that can be used to convert a static ggplot2 object into an interactive plot.
Expand All @@ -620,8 +604,6 @@ tooltip_css <- "background-color:#e7eef3;font-family:Roboto;padding:10px;border-
ggiraph(code=print(p),hover_css="cursor:pointer;stroke:black;fill-opacity:0.3",zoom_max=5,tooltip_extra_css=tooltip_css,tooltip_opacity=0.9)
```

`r fc(name="interactive_ggiraph",caption="_Interactive scatterplot using ggiraph._")`

## dygraphs

R package [`dygraphs`](http://rstudio.github.io/dygraphs/) provides R bindings for javascript library [dygraphs](http://dygraphs.com/) for time series data.
Expand All @@ -632,8 +614,6 @@ dygraph(lungDeaths,main="Deaths from Lung Disease (UK)") %>%
dyOptions(colors=c("#66C2A5","#FC8D62","#8DA0CB"))
```

`r fc(name="interactive_dygraph",caption="_Interactive time series plot using dygraph._")`

## Network graph

R package `networkD3` allows the use of interactive network graphs from the [D3.js](https://d3js.org/) javascript library.
Expand All @@ -645,8 +625,6 @@ forceNetwork(Links=MisLinks,Nodes=MisNodes,Source="source",
Group="group",opacity=0.4)
```

`r fc(name="interactive_network",caption="_Interactive network plot._")`

## leaflet

R package [`leaflet`](https://rstudio.github.io/leaflet/) provides R bindings for javascript mapping library; [leafletjs](http://leafletjs.com/).
Expand All @@ -659,8 +637,6 @@ leaflet(height=500,width=700) %>%
setView(lat=41.84201,lng=-89.485937,zoom=15)
```

`r fc(name="interactive_map",caption="_Interactive map using leaflet._")`

## crosstalk

R package [`crosstalk`](https://rstudio.github.io/crosstalk/index.html) allows `crosstalk` enabled plotting libraries to be linked. Through the shared 'key' variable, data points can be manipulated simultaneously on two independent plots.
Expand All @@ -676,8 +652,6 @@ py <- plot_ly(shared_quakes,x=~depth,y=~mag,size=~stations,height=300) %>%
htmltools::div(lf,py)
```

`r fc(name="interactive_crosstalk",caption="_Linking independent plots using crosstalk._")`

# Alerts

```
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,12 @@
# load libraries
library(knitr) # runs pandoc
library(bookdown) # for markdown
library(captioner) # for table and figure captions
# fontawesome dependency
#fa <- rmarkdown::html_dependency_font_awesome()
#fa$attachment <- "fonts/fontawesome-webfont.ttf"
#htmltools::tagList(fa)
# prepare captions
tc <- captioner::captioner(prefix="<b>Tab. </b>")
fc <- captioner::captioner(prefix="<b>Fig. </b>")
# turn off terminal colors
options(crayon.enabled = FALSE)
Expand Down

0 comments on commit 58ced81

Please sign in to comment.