Grammar is:
How to speak and make sense
For example, if we say
make how speak and to sense
we have the same words, but they do not make sense
In English we say
John eats fruit
John slowly eats fresh fruit
There are many explanations on the web. Google them
ggplot2
There was an old “ggplot” package. We use the second version.
This package gives us many commands. The basic ones are
ggplot()
geom_point()
, geom_line()
, and other geom_…
commandsscale_x_…
, scale_y_…
, and other scale_…
commandstheme
Warning: Removed 18 rows containing missing values (geom_point).
ggplot()
. It takes two inputs
students
aes()
object, called aesthetic mapaes()
describe how data frame columns are mapped to visual properties (aesthetics)
x=
and y=
partsgeom_point()
size
can show some dataalpha
geom_point()
color
and fill
# A tibble: 7 x 2
WHO_region `n_distinct(Country)`
<chr> <int>
1 AFRO 50
2 AMRO 56
3 EMRO 22
4 EURO 62
5 Other 1
6 SEARO 11
7 WPRO 35
The easiest case is SEARO
: South East Asia