How does "+" work in ggplot2?

This is apparently a simple question that I am asking to better understand how domain languages ​​work in R.

How does the general "+" function allow you to build a layered graph in ggplot2?

Obviously, it ggplot2works at a very high level of abstraction. Can someone show a simple example showing how the β€œ+” works under the hood with ggplot2?

+4
source share
1 answer

methods("+")will display marked "+.gg*", not exported from ggplot2.

ggplot2:::`+.gg` 

will show the beast.

: , + - R, . ggplot2 gg; , , , . getAnywhere("+.gg").

+5

Source: https://habr.com/ru/post/1542986/


All Articles