Skip to content

Commit

Permalink
update R playground
Browse files Browse the repository at this point in the history
  • Loading branch information
joannytan committed Feb 15, 2025
1 parent 72594a9 commit d922cce
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 7 deletions.
4 changes: 2 additions & 2 deletions docs/playground/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -346,7 +346,7 @@
// Document level settings ----

// Determine if we need to install R packages
globalThis.qwebrInstallRPackagesList = ['fpp3', 'ggplot2', 'tidyverse', 'glue'];
globalThis.qwebrInstallRPackagesList = ['fpp3', 'ggplot2', 'tidyverse'];

// Specify possible locations to search for the repository
globalThis.qwebrPackageRepoURLS = ['https://repo.r-wasm.org/'];
Expand All @@ -368,7 +368,7 @@
};

// Store cell data
globalThis.qwebrCellDetails = [{"options":{"message":"true","fig-cap":"","editor-font-scale":"1","autorun":"false","classes":"","context":"interactive","editor-max-height":"","fig-height":5,"editor-word-wrap":"true","dpi":72,"results":"markup","fig-width":7,"comment":"","out-width":"700px","output":"true","read-only":"false","warning":"true","editor-quick-suggestions":"false","out-height":"","label":"unnamed-chunk-1"},"code":"fit = lm(mpg ~ am, data = mtcars)\n\nsummary(fit)","id":1}];
globalThis.qwebrCellDetails = [{"code":"# write your code here","id":1,"options":{"dpi":72,"read-only":"false","classes":"","context":"interactive","label":"unnamed-chunk-1","fig-width":7,"fig-height":5,"editor-quick-suggestions":"false","warning":"true","message":"true","results":"markup","fig-cap":"","editor-font-scale":"1","editor-max-height":"","output":"true","autorun":"false","comment":"","editor-word-wrap":"true","out-height":"","out-width":"700px"}}];

</script>
<script type="module">
Expand Down
2 changes: 1 addition & 1 deletion docs/sitemap.xml
Original file line number Diff line number Diff line change
Expand Up @@ -238,6 +238,6 @@
</url>
<url>
<loc>https://bf.numbat.space/playground/index.html</loc>
<lastmod>2025-02-07T03:22:21.758Z</lastmod>
<lastmod>2025-02-15T06:37:04.522Z</lastmod>
</url>
</urlset>
9 changes: 5 additions & 4 deletions playground/index.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,14 @@ title: "R Playground"
filters:
- webr
webr:
packages: ['fpp3', 'ggplot2', 'tidyverse', 'glue']
packages:
- 'fpp3'
- 'ggplot2'
- 'tidyverse'
---

This is the web version of R.

```{webr-r}
fit = lm(mpg ~ am, data = mtcars)
summary(fit)
# write your code here
```

0 comments on commit d922cce

Please sign in to comment.