Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

use litedown for rendering vignettes #6583

Draft
wants to merge 6 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .dev/CRAN_Release.cmd
Original file line number Diff line number Diff line change
Expand Up @@ -344,7 +344,7 @@ Rdevel-strict-[gcc|clang] CMD check data.table_1.16.99.tar.gz
Rdevel-strict-[gcc|clang]
isTRUE(.Machine$sizeof.longdouble==0) # check noLD is being tested
options(repos = "http://cloud.r-project.org")
install.packages(c("bit64", "bit", "R.utils", "xts", "zoo", "yaml", "knitr", "markdown"),
install.packages(c("bit64", "bit", "R.utils", "xts", "zoo", "yaml", "litedown"),
Ncpus=4)
# Issue #5491 showed that CRAN is running UBSAN on .Rd examples which found an error so we now run full R CMD check
q("no")
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/R-CMD-check-occasional.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ jobs:
TEST_DATA_TABLE_WITH_OTHER_PACKAGES=as.character(run_other)
)

do_vignettes = requireNamespace("knitr", quietly=TRUE)
do_vignettes = requireNamespace("litedown", quietly=TRUE)

build_args = NULL
check_args = c("--no-manual", "--as-cran")
Expand Down
4 changes: 2 additions & 2 deletions DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,12 @@ Version: 1.16.99
Title: Extension of `data.frame`
Depends: R (>= 3.3.0)
Imports: methods
Suggests: bit64 (>= 4.0.0), bit (>= 4.0.4), R.utils, xts, zoo (>= 1.8-1), yaml, knitr, markdown
Suggests: bit64 (>= 4.0.0), bit (>= 4.0.4), R.utils, xts, zoo (>= 1.8-1), yaml, litedown
Description: Fast aggregation of large data (e.g. 100GB in RAM), fast ordered joins, fast add/modify/delete of columns by group using no copies at all, list columns, friendly and fast character-separated-value read/write. Offers a natural and flexible syntax, for faster development.
License: MPL-2.0 | file LICENSE
URL: https://r-datatable.com, https://Rdatatable.gitlab.io/data.table, https://github.com/Rdatatable/data.table
BugReports: https://github.com/Rdatatable/data.table/issues
VignetteBuilder: knitr
VignetteBuilder: litedown
Encoding: UTF-8
ByteCompile: TRUE
Authors@R: c(
Expand Down
12 changes: 10 additions & 2 deletions vignettes/datatable-benchmarking.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -2,18 +2,26 @@
title: "Benchmarking data.table"
date: "`r Sys.Date()`"
output:
markdown::html_format:
litedown::html_format:
options:
toc: true
number_sections: true
meta:
css: [default, css/toc.css]
vignette: >
%\VignetteIndexEntry{Benchmarking data.table}
%\VignetteEngine{knitr::knitr}
%\VignetteEngine{litedown::vignette}
\usepackage[utf8]{inputenc}
---

```{r, echo = FALSE, message = FALSE}
library(data.table)
opts = litedown::reactor()
opts$comment = "# "
opts$error = FALSE
opts$print = xfun:::record_print.default

Check warning on line 22 in vignettes/datatable-benchmarking.Rmd

View workflow job for this annotation

GitHub Actions / lint-r

file=vignettes/datatable-benchmarking.Rmd,line=22,col=18,[undesirable_operator_linter] Avoid undesirable operator `:::`. It accesses non-exported functions inside packages. Code relying on these is likely to break in future versions of the package because the functions are not part of the public interface and may be changed or removed by the maintainers without notice. Use public functions via `::` instead.
```

<style>
h2 {
font-size: 20px;
Expand Down
23 changes: 10 additions & 13 deletions vignettes/datatable-faq.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,25 @@
title: "Frequently Asked Questions about data.table"
date: "`r Sys.Date()`"
output:
markdown::html_format:
litedown::html_format:
options:
toc: true
number_sections: true
meta:
css: [default, css/toc.css]
vignette: >
%\VignetteIndexEntry{Frequently Asked Questions about data.table}
%\VignetteEngine{knitr::knitr}
%\VignetteEngine{litedown::vignette}
\usepackage[utf8]{inputenc}
---
```{r, echo = FALSE, message = FALSE}
library(data.table)
opts = litedown::reactor()
opts$comment = "# "
opts$error = FALSE
opts$print = xfun:::record_print.default

Check warning on line 21 in vignettes/datatable-faq.Rmd

View workflow job for this annotation

GitHub Actions / lint-r

file=vignettes/datatable-faq.Rmd,line=21,col=18,[undesirable_operator_linter] Avoid undesirable operator `:::`. It accesses non-exported functions inside packages. Code relying on these is likely to break in future versions of the package because the functions are not part of the public interface and may be changed or removed by the maintainers without notice. Use public functions via `::` instead.
.old.th = setDTthreads(1)
```

<style>
h2 {
Expand All @@ -21,17 +29,6 @@
#TOC { width: 100%; }
</style>

```{r, echo = FALSE, message = FALSE}
library(data.table)
knitr::opts_chunk$set(
comment = "#",
error = FALSE,
tidy = FALSE,
cache = FALSE,
collapse = TRUE)
.old.th = setDTthreads(1)
```

The first section, Beginner FAQs, is intended to be read in order, from start to finish. It's just written in a FAQ style to be digested more easily. It isn't really the most frequently asked questions. A better measure for that is looking on Stack Overflow.

This FAQ is required reading and considered core documentation. Please do not ask questions on Stack Overflow or raise issues on GitHub until you have read it. We can all tell when you ask that you haven't read it. So if you do ask and haven't read it, don't use your real name.
Expand Down
12 changes: 10 additions & 2 deletions vignettes/datatable-importing.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,21 @@
title: "Importing data.table"
date: "`r Sys.Date()`"
output:
markdown::html_format
litedown::html_format
vignette: >
%\VignetteIndexEntry{Importing data.table}
%\VignetteEngine{knitr::knitr}
%\VignetteEngine{litedown::vignette}
\usepackage[utf8]{inputenc}
---

```{r, echo = FALSE, message = FALSE}
opts = litedown::reactor()
opts$comment = "# "
opts$error = FALSE
opts$print = xfun:::record_print.default

Check warning on line 16 in vignettes/datatable-importing.Rmd

View workflow job for this annotation

GitHub Actions / lint-r

file=vignettes/datatable-importing.Rmd,line=16,col=18,[undesirable_operator_linter] Avoid undesirable operator `:::`. It accesses non-exported functions inside packages. Code relying on these is likely to break in future versions of the package because the functions are not part of the public interface and may be changed or removed by the maintainers without notice. Use public functions via `::` instead.
.old.th = setDTthreads(1)
```

<style>
h2 {
font-size: 20px;
Expand Down
17 changes: 7 additions & 10 deletions vignettes/datatable-intro.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -2,22 +2,19 @@
title: "Introduction to data.table"
date: "`r Sys.Date()`"
output:
markdown::html_format
litedown::html_format
vignette: >
%\VignetteIndexEntry{Introduction to data.table}
%\VignetteEngine{knitr::knitr}
%\VignetteEngine{litedown::vignette}
\usepackage[utf8]{inputenc}
---

```{r, echo = FALSE, message = FALSE}
require(data.table)
knitr::opts_chunk$set(
comment = "#",
error = FALSE,
tidy = FALSE,
cache = FALSE,
collapse = TRUE
)
library(data.table)
opts = litedown::reactor()
opts$comment = "# "
opts$error = FALSE
opts$print = xfun:::record_print.default

Check warning on line 17 in vignettes/datatable-intro.Rmd

View workflow job for this annotation

GitHub Actions / lint-r

file=vignettes/datatable-intro.Rmd,line=17,col=18,[undesirable_operator_linter] Avoid undesirable operator `:::`. It accesses non-exported functions inside packages. Code relying on these is likely to break in future versions of the package because the functions are not part of the public interface and may be changed or removed by the maintainers without notice. Use public functions via `::` instead.
.old.th = setDTthreads(1)
```

Expand Down
17 changes: 7 additions & 10 deletions vignettes/datatable-joins.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -2,24 +2,21 @@
title: "Joins in data.table"
date: "`r Sys.Date()`"
output:
markdown::html_format
litedown::html_format
vignette: >
%\VignetteIndexEntry{Joins in data.table}
%\VignetteEngine{knitr::knitr}
%\VignetteEngine{litedown::vignette}
\usepackage[utf8]{inputenc}
editor_options:
chunk_output_type: console
---

```{r, echo = FALSE, message = FALSE}
require(data.table)
knitr::opts_chunk$set(
comment = "#",
error = FALSE,
tidy = FALSE,
cache = FALSE,
collapse = TRUE
)
library(data.table)
opts = litedown::reactor()
opts$comment = "# "
opts$error = FALSE
opts$print = xfun:::record_print.default

Check warning on line 19 in vignettes/datatable-joins.Rmd

View workflow job for this annotation

GitHub Actions / lint-r

file=vignettes/datatable-joins.Rmd,line=19,col=18,[undesirable_operator_linter] Avoid undesirable operator `:::`. It accesses non-exported functions inside packages. Code relying on these is likely to break in future versions of the package because the functions are not part of the public interface and may be changed or removed by the maintainers without notice. Use public functions via `::` instead.
```

In this vignette you will learn how to perform any join operation using resources available in the `data.table` syntax.
Expand Down
16 changes: 7 additions & 9 deletions vignettes/datatable-keys-fast-subset.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -2,21 +2,19 @@
title: "Keys and fast binary search based subset"
date: "`r Sys.Date()`"
output:
markdown::html_format
litedown::html_format
vignette: >
%\VignetteIndexEntry{Keys and fast binary search based subset}
%\VignetteEngine{knitr::knitr}
%\VignetteEngine{litedown::vignette}
\usepackage[utf8]{inputenc}
---

```{r, echo = FALSE, message = FALSE}
require(data.table)
knitr::opts_chunk$set(
comment = "#",
error = FALSE,
tidy = FALSE,
cache = FALSE,
collapse = TRUE)
library(data.table)
opts = litedown::reactor()
opts$comment = "# "
opts$error = FALSE
opts$print = xfun:::record_print.default

Check warning on line 17 in vignettes/datatable-keys-fast-subset.Rmd

View workflow job for this annotation

GitHub Actions / lint-r

file=vignettes/datatable-keys-fast-subset.Rmd,line=17,col=18,[undesirable_operator_linter] Avoid undesirable operator `:::`. It accesses non-exported functions inside packages. Code relying on these is likely to break in future versions of the package because the functions are not part of the public interface and may be changed or removed by the maintainers without notice. Use public functions via `::` instead.
.old.th = setDTthreads(1)
```

Expand Down
19 changes: 8 additions & 11 deletions vignettes/datatable-programming.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -2,22 +2,19 @@
title: "Programming on data.table"
date: "`r Sys.Date()`"
output:
markdown::html_format
litedown::html_format
vignette: >
%\VignetteIndexEntry{Programming on data.table}
%\VignetteEngine{knitr::knitr}
%\VignetteEngine{litedown::vignette}
\usepackage[utf8]{inputenc}
---

```{r init, include = FALSE}
require(data.table)
knitr::opts_chunk$set(
comment = "#",
error = FALSE,
tidy = FALSE,
cache = FALSE,
collapse = TRUE
)
```{r init, echo = FALSE, message = FALSE}
library(data.table)
opts = litedown::reactor()
opts$comment = "# "
opts$error = FALSE
opts$print = xfun:::record_print.default

Check warning on line 17 in vignettes/datatable-programming.Rmd

View workflow job for this annotation

GitHub Actions / lint-r

file=vignettes/datatable-programming.Rmd,line=17,col=18,[undesirable_operator_linter] Avoid undesirable operator `:::`. It accesses non-exported functions inside packages. Code relying on these is likely to break in future versions of the package because the functions are not part of the public interface and may be changed or removed by the maintainers without notice. Use public functions via `::` instead.
```


Expand Down
16 changes: 7 additions & 9 deletions vignettes/datatable-reference-semantics.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -2,21 +2,19 @@
title: "Reference semantics"
date: "`r Sys.Date()`"
output:
markdown::html_format
litedown::html_format
vignette: >
%\VignetteIndexEntry{Reference semantics}
%\VignetteEngine{knitr::knitr}
%\VignetteEngine{litedown::vignette}
\usepackage[utf8]{inputenc}
---

```{r, echo = FALSE, message = FALSE}
require(data.table)
knitr::opts_chunk$set(
comment = "#",
error = FALSE,
tidy = FALSE,
cache = FALSE,
collapse = TRUE)
library(data.table)
opts = litedown::reactor()
opts$comment = "# "
opts$error = FALSE
opts$print = xfun:::record_print.default

Check warning on line 17 in vignettes/datatable-reference-semantics.Rmd

View workflow job for this annotation

GitHub Actions / lint-r

file=vignettes/datatable-reference-semantics.Rmd,line=17,col=18,[undesirable_operator_linter] Avoid undesirable operator `:::`. It accesses non-exported functions inside packages. Code relying on these is likely to break in future versions of the package because the functions are not part of the public interface and may be changed or removed by the maintainers without notice. Use public functions via `::` instead.
.old.th = setDTthreads(1)
```
This vignette discusses *data.table*'s reference semantics which allows to *add/update/delete* columns of a *data.table by reference*, and also combine them with `i` and `by`. It is aimed at those who are already familiar with *data.table* syntax, its general form, how to subset rows in `i`, select and compute on columns, and perform aggregations by group. If you're not familiar with these concepts, please read the `vignette("datatable-intro", package="data.table")` first.
Expand Down
16 changes: 7 additions & 9 deletions vignettes/datatable-reshape.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -2,21 +2,19 @@
title: "Efficient reshaping using data.tables"
date: "`r Sys.Date()`"
output:
markdown::html_format
litedown::html_format
vignette: >
%\VignetteIndexEntry{Efficient reshaping using data.tables}
%\VignetteEngine{knitr::knitr}
%\VignetteEngine{litedown::vignette}
\usepackage[utf8]{inputenc}
---

```{r, echo = FALSE, message = FALSE}
require(data.table)
knitr::opts_chunk$set(
comment = "#",
error = FALSE,
tidy = FALSE,
cache = FALSE,
collapse = TRUE)
library(data.table)
opts = litedown::reactor()
opts$comment = "# "
opts$error = FALSE
opts$print = xfun:::record_print.default

Check warning on line 17 in vignettes/datatable-reshape.Rmd

View workflow job for this annotation

GitHub Actions / lint-r

file=vignettes/datatable-reshape.Rmd,line=17,col=18,[undesirable_operator_linter] Avoid undesirable operator `:::`. It accesses non-exported functions inside packages. Code relying on these is likely to break in future versions of the package because the functions are not part of the public interface and may be changed or removed by the maintainers without notice. Use public functions via `::` instead.
.old.th = setDTthreads(1)
```

Expand Down
19 changes: 7 additions & 12 deletions vignettes/datatable-sd-usage.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -2,29 +2,24 @@
title: "Using .SD for Data Analysis"
date: "`r Sys.Date()`"
output:
markdown::html_format:
litedown::html_format:
options:
toc: true
number_sections: true
meta:
css: [default, css/toc.css]
vignette: >
%\VignetteIndexEntry{Using .SD for Data Analysis}
%\VignetteEngine{knitr::knitr}
%\VignetteEngine{litedown::vignette}
\usepackage[utf8]{inputenc}
---

```{r, echo = FALSE, message = FALSE}
require(data.table)
knitr::opts_chunk$set(
comment = "#",
error = FALSE,
tidy = FALSE,
cache = FALSE,
collapse = TRUE,
out.width = '100%',
dpi = 144
)
library(data.table)
opts = litedown::reactor()
opts$comment = "# "
opts$error = FALSE
opts$print = xfun:::record_print.default

Check warning on line 22 in vignettes/datatable-sd-usage.Rmd

View workflow job for this annotation

GitHub Actions / lint-r

file=vignettes/datatable-sd-usage.Rmd,line=22,col=18,[undesirable_operator_linter] Avoid undesirable operator `:::`. It accesses non-exported functions inside packages. Code relying on these is likely to break in future versions of the package because the functions are not part of the public interface and may be changed or removed by the maintainers without notice. Use public functions via `::` instead.
.old.th = setDTthreads(1)
```

Expand Down
16 changes: 7 additions & 9 deletions vignettes/datatable-secondary-indices-and-auto-indexing.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -2,21 +2,19 @@
title: "Secondary indices and auto indexing"
date: "`r Sys.Date()`"
output:
markdown::html_format
litedown::html_format
vignette: >
%\VignetteIndexEntry{Secondary indices and auto indexing}
%\VignetteEngine{knitr::knitr}
%\VignetteEngine{litedown::vignette}
\usepackage[utf8]{inputenc}
---

```{r, echo = FALSE, message = FALSE}
require(data.table)
knitr::opts_chunk$set(
comment = "#",
error = FALSE,
tidy = FALSE,
cache = FALSE,
collapse = TRUE)
library(data.table)
opts = litedown::reactor()
opts$comment = "# "
opts$error = FALSE
opts$print = xfun:::record_print.default
.old.th = setDTthreads(1)
```

Expand Down
Loading