---
title: "Getting started"
output: rmarkdown::html_vignette
vignette: >
%\VignetteIndexEntry{Getting started}
%\VignetteEngine{knitr::rmarkdown}
%\VignetteEncoding{UTF-8}
---
```R
hgd()
```
Copy the displayed link in the browser or call
```R
hgd_browse()
```
to open a browser window automatically.
Plot anything.
```R
x = seq(0, 3 * pi, by = 0.1)
plot(x, sin(x), type = "l")
```
Every plotting library will work.
```R
library(ggplot2)
ggplot(mpg, aes(displ, hwy, colour = class)) +
geom_point()
```
Stop the server with:
```R
dev.off()
```
## Keyboard shortcuts
| Keys | Result |
|:----:|--------|
| ← → ↑ ↓ | Navigate plot history. |
| + / - | Zoom in and out. |
| 0 | Reset zoom level. |
| N | Jump to the newest plot. |
| del / D | Delete plot. |
| alt+D | Clear all plots. |
| S | Download plot as SVG. |
| P | Download plot as PNG. |
| C | Copy plot to clipboard (as PNG). |
| H | Toggle plot history (sidebar). |
## See also
See also the [plotting in `unigd`](https://nx10.github.io/unigd/articles/b00_guide.html) guide.