knitr::opts_chunk$set(
  collapse = TRUE,
  comment = "#>",
  fig.path = "man/figures/README-",
  out.width = "100%"
)

surfcast

The surfcast package and app make it easy to find the best place to surf during a given season or month. The data comes from https://www.surf-forecast.com/.

Installation

You can install the development version of surfcast with:

# install.packages("devtools")
devtools::install_github("maurolepore/surfcast")

Example

Use the database online. You may also access the data via a shiny app or directly in R.

library(surfcast)
library(dplyr, warn.conflicts = FALSE)
run_app()
best_conditions
best_conditions %>% 
  distinct(country) %>% 
  pull()

I'm in Argentina. Where should I go surfing today?

ne <- "north|east"
nw <- "north|west"
# Not
sw <- "south|west"
se <- "south|east"

best_conditions %>%
  filter(country == "argentina") %>% 
  filter(grepl(ne, tolower(best_swell))) %>%
  filter(!grepl(sw, tolower(best_swell))) %>%
  filter(grepl(nw, tolower(best_wind))) %>% 
  filter(!grepl(se, tolower(best_wind)))


maurolepore/surfcast documentation built on April 9, 2022, 12:50 p.m.