Skip to content

Commit 0496ac1

Browse files
authored
Spring clean for CRAN update (#43)
1 parent 498d247 commit 0496ac1

File tree

6 files changed

+28
-25
lines changed

6 files changed

+28
-25
lines changed

.lintr

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,9 @@
1-
linters: with_defaults(
2-
line_length_linter(100),
3-
assignment_linter = NULL,
4-
undesirable_operator_linter = undesirable_operator_linter(
5-
with_defaults(
6-
default_undesirable_operators,
7-
"<-" = "Use =, not <-, for assignment."
8-
)
9-
)
10-
)
1+
linters: linters_with_defaults(
2+
assignment_linter = NULL,
3+
indentation_linter = NULL,
4+
commented_code_linter = NULL,
5+
object_length_linter = NULL,
6+
line_length_linter(100),
7+
cyclocomp_linter(complexity_limit = 15),
8+
undesirable_operator_linter = undesirable_operator_linter(
9+
op = list("<-" = "Please use '=' for assignment")))

DESCRIPTION

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
Package: datasauRus
22
Title: Datasets from the Datasaurus Dozen
3-
Version: 0.1.8
3+
Version: 0.1.9
44
Authors@R: c(
55
person("Colin", "Gillespie", , "colin@jumpingrivers.com", role = c("cre", "aut")),
66
person("Steph", "Locke", , "stephanie.g.locke@gmail.com", role = "aut"),
77
person("Alberto", "Cairo", , "alberto.cairo@gmail.com", role = "dtc"),
8-
person("Rhian", "Davies", , "statsrhian@gmail.com", role = c("aut")),
8+
person("Rhian", "Davies", , "statsrhian@gmail.com", role = "aut"),
99
person("Justin", "Matejka", , "Justin.Matejka@autodesk.com", role = "dtc"),
1010
person("George", "Fitzmaurice", , "George.Fitzmaurice@autodesk.com", role = "dtc"),
1111
person("Lucy", "D'Agostino McGowan", , "ld.mcgowan@vanderbilt.edu", role = "aut"),
@@ -42,7 +42,7 @@ Suggests:
4242
VignetteBuilder:
4343
knitr
4444
Encoding: UTF-8
45+
Language: en-US
4546
LazyData: true
4647
Roxygen: list(markdown = TRUE)
47-
RoxygenNote: 7.2.3
48-
Language: en-US
48+
RoxygenNote: 7.3.2

Datasaurus.Rproj

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
Version: 1.0
2+
ProjectId: 16075796-80fe-42ac-87e0-61c1c1ac3f33
23

34
RestoreWorkspace: No
45
SaveWorkspace: No

NEWS.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
# datasauRus 0.1.9
2+
* Spring clean: linting
3+
14
# datasauRus 0.1.8
25

36
* Update maintainer

tests/testthat/test-datasets.R

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
context("datasets")
22

33
datashapetests = function(df, ncols, nrows, uniquecol = NULL, nuniques = NULL) {
4-
expect_equal(ncol(df), ncols)
5-
expect_equal(nrow(df), nrows)
4+
testthat::expect_equal(ncol(df), ncols)
5+
testthat::expect_equal(nrow(df), nrows)
66
if (!is.null(uniquecol)) {
7-
expect_equal(nrow(unique(df[uniquecol])), nuniques)
7+
testthat::expect_equal(nrow(unique(df[uniquecol])), nuniques)
88
}
99
}
1010

vignettes/Datasaurus.Rmd

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -24,10 +24,10 @@ To see that statistics are (almost) the same for each sub-dataset, you can use `
2424

2525
```{r}
2626
library(datasauRus)
27-
if(requireNamespace("dplyr")){
27+
if (requireNamespace("dplyr")) {
2828
suppressPackageStartupMessages(library(dplyr))
29-
datasaurus_dozen %>%
30-
group_by(dataset) %>%
29+
datasaurus_dozen %>%
30+
group_by(dataset) %>%
3131
summarize(
3232
mean_x = mean(x),
3333
mean_y = mean(y),
@@ -41,12 +41,12 @@ if(requireNamespace("dplyr")){
4141
To see that each sub-dataset looks very different, you can draw scatter plots.
4242

4343
```{r fig.height=12, fig.width=9}
44-
if(requireNamespace("ggplot2")){
44+
if (requireNamespace("ggplot2")) {
4545
library(ggplot2)
46-
ggplot(datasaurus_dozen, aes(x = x, y = y, colour = dataset))+
47-
geom_point()+
48-
theme_void()+
49-
theme(legend.position = "none")+
46+
ggplot(datasaurus_dozen, aes(x = x, y = y, colour = dataset)) +
47+
geom_point() +
48+
theme_void() +
49+
theme(legend.position = "none") +
5050
facet_wrap(~dataset, ncol = 3)
5151
}
5252
```

0 commit comments

Comments
 (0)