Skip to main content

Scrape surf conditions from surf-report.com

Project description

Surf Scrap - surfscraphb

surfscraphb is a Python package that allows you to extract surf conditions
from surf-report.com and save them into a CSV file for further analysis or dashboard creation.

This package was developed as part of a data analysis project to help surf schools identify the best moments to practice surfing during the week.

PyPI version License: MIT

Features

  • Scrapes surf conditions from surf-report.com
  • Works with multiple surf spots (Lacanau, Carcans, Moliets, etc.)
  • Extracts:
    • Day
    • Hour
    • Wave size
    • Wind speed (km/h)
    • Wind direction
  • Saves the data as a CSV file
  • Returns a pandas DataFrame for immediate use
  • Simple API with one main function

Installation

Install the package from PyPI:

pip install surfscraphb

Quick Start

from surfscraphb import scrape_surf_report

scrape_surf_report(
    "https://www.surf-report.com/meteo-surf/carcans-plage-s1013.html",
    "carcans.csv"
)

After execution, a file carcans.csv will be created in your working directory. You can change the name carcans.csv to an other one.

Function Documentation

scrape_surf_report(url, output_csv)

Scrapes surf conditions from a surf-report.com page and saves the data to a CSV file.

Parameters:

Name Type Description
url str URL of the surf-report page
output_csv str Path where the CSV file will be saved

Returns

  • pandas.DataFrame containing the extracted surf conditions.

Output Data Format

The generated CSV file contains the following columns:

Column Description
Day Day of the forecast
Hour Time of the forecast
Wave_size_m Wave size range (meters)
Wind_speed_km_h Wind speed (km/h)
Wind_direction Wind direction

Notes & Limitations

  • The package relies on the current HTML structure of surf-report.com.
  • If the website structure changes, the scraper may require updates.
  • This project is intended for educational and analytical purposes.

Dependencies

  • Python ≥ 3.12
  • requests
  • beautifulsoup4
  • pandas

All dependencies are automatically installed via pip.

Licence

This project is licensed under the MIT License. You are free to use, modify, and distribute it.


Useful Links

PyPI : https://pypi.org/project/surfscraphb/

Authors

  • MISSONGO Aimé Blanchard
  • Hippolyte SODJINOU

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

surfscraphb-0.0.1.tar.gz (4.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

surfscraphb-0.0.1-py3-none-any.whl (4.5 kB view details)

Uploaded Python 3

File details

Details for the file surfscraphb-0.0.1.tar.gz.

File metadata

  • Download URL: surfscraphb-0.0.1.tar.gz
  • Upload date:
  • Size: 4.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for surfscraphb-0.0.1.tar.gz
Algorithm Hash digest
SHA256 19489236a779895db4520f791a34faa35a7f9045af50e7ccccaf90bd0d1b0b77
MD5 ce1850b5900a89a019531a613ae838d0
BLAKE2b-256 5d645d7b7b00b2d536af0a8532b266295da1974a5b483a2d08f9284b6d3bdea4

See more details on using hashes here.

File details

Details for the file surfscraphb-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: surfscraphb-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 4.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for surfscraphb-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 8885aeb0dcd91540327fe902eebbf0c9fdb6de1f33cae87892bd0e0aeebaa09d
MD5 1d7e7cd84310a25ef2b38a237ab93580
BLAKE2b-256 090ac44829ea47c9949c7092764e6f27c4e0f13fb8d787d85628da75a19e8b10

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page