Description Usage Arguments Value Examples
View source: R/geom_timeline.R
Geom function for creating the timeline from Earthquake data from NOAA
1 2 3 4 5 6 7 8 9 10 11 12 |
mapping |
set aesthetics |
data |
The data of which we want to make the timeline |
stat |
The statistics that you want to use |
position |
Position of the string |
na.rm |
If False, null value are removed |
show.legend |
Should layer have a legend or not |
inherit.aes |
Basically inherit the aesthetics or not |
xmin |
Providing the minimum date for the data to be plotted |
xmax |
Providing maximum date for the data to be plotted |
... |
Other arguments that can be passed |
This return the geom timeline
1 2 3 4 5 6 7 8 9 10 11 | ## Not run:
data(NOAA_data)
NOAA_data %>% eq_clean_data() %>%
dplyr::filter(Country %in% c("India", "Pakistan")) %>%
ggplot(aes(x = date, y = Country, color = Total.Deaths, size = Mag,
magnitude = Mag, label =Location_Name)) +
labs(color="#deaths",size="Magnitude",x="DATE")+
geom_timeline(alpha=0.2,xmin = ymd('2000-01-01'), xmax = ymd('2015-12-31'))+
labs(x="DATE")+theme_minimal()
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.