Skip to content

Commit

Permalink
thickness pkgdown article for #205
Browse files Browse the repository at this point in the history
  • Loading branch information
mjskay committed Jan 14, 2024
1 parent a3be3a1 commit 0a9779d
Show file tree
Hide file tree
Showing 24 changed files with 1,068 additions and 8 deletions.
1 change: 1 addition & 0 deletions .Rbuildignore
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
^data-raw$
^figures-source$
^vignettes/.*_cache$
^vignettes/thickness\.Rmd$
^revdep$
^man/figures$
^man-roxygen$
Expand Down
5 changes: 5 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,11 @@ New features and enhancements:
* The `arrow` parameter is now supported for intervals in `geom_slabinterval()`
(#206; thanks to @ASKurz for the suggestion).

Documentation:

* The pkgdown documentation now includes an online article on the `thickness`
aesthetic and how its scaling works.

Bug fixes:

* Ensure `Mode()` works on analytical constant distributions.
Expand Down
4 changes: 2 additions & 2 deletions R/stat_slabinterval.R
Original file line number Diff line number Diff line change
Expand Up @@ -726,7 +726,7 @@ stat_eye = make_stat(StatEye, geom = "slabinterval")

StatCcdfinterval = ggproto("StatCcdfinterval", StatSlabinterval,
default_aes = defaults(aes(
thickness = after_stat(thickness(1 - cdf)),
thickness = after_stat(thickness(1 - cdf, 0, 1)),
justification = after_stat(0.5),
side = after_stat("topleft"),
), StatSlabinterval$default_aes),
Expand All @@ -744,7 +744,7 @@ stat_ccdfinterval = make_stat(StatCcdfinterval, geom = "slabinterval")

StatCdfinterval = ggproto("StatCdfinterval", StatCcdfinterval,
default_aes = defaults(aes(
thickness = after_stat(thickness(cdf)),
thickness = after_stat(thickness(cdf, 0, 1)),
), StatCcdfinterval$default_aes),

default_slab_type = "cdf"
Expand Down
7 changes: 6 additions & 1 deletion docs/articles/index.html

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

612 changes: 612 additions & 0 deletions docs/articles/thickness.html

Large diffs are not rendered by default.

Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion tests/testthat/test.subguide.R
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ test_that("dots subguide works with side and justification", {
ggplot(aes(xdist = x)) +
scale_x_continuous(expand = expansion(add = 0.3))

sg = subguide_count(title = "num", label_side = "left")
sg = subguide_count(title = "num", label_side = "left", theme = theme_test())
vdiffr::expect_doppelganger("dots subguide with side",
p +
stat_dotsinterval(aes(y = "1 bottom"), subguide = sg, side = "bottom", quantiles = 50, stackratio = 1.25) +
Expand Down
2 changes: 1 addition & 1 deletion vignettes/dotsinterval.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ theme_set(theme_ggdist())
```

```{r hidden_options, include=FALSE}
.old_options = options(width = 120)
.old_options = options(width = 110)
```


Expand Down
2 changes: 1 addition & 1 deletion vignettes/freq-uncertainty-vis.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ theme_set(theme_ggdist())
```

```{r hidden_options, include=FALSE}
.old_options = options(width = 120)
.old_options = options(width = 110)
```


Expand Down
2 changes: 1 addition & 1 deletion vignettes/lineribbon.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ theme_set(theme_ggdist())
```

```{r hidden_options, include=FALSE}
.old_options = options(width = 120)
.old_options = options(width = 110)
```


Expand Down
2 changes: 1 addition & 1 deletion vignettes/slabinterval.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ theme_set(theme_ggdist())
```

```{r hidden_options, include=FALSE}
.old_options = options(width = 120)
.old_options = options(width = 110)
```


Expand Down
Loading

0 comments on commit 0a9779d

Please sign in to comment.