read_imd_rainfall: Read IMD NetCDF rainfall file

View source: R/imd_processing.R

read_imd_rainfallR Documentation

Read IMD NetCDF rainfall file

Description

Reads IMD NetCDF rainfall data and converts the data to a data.frame.

Usage

read_imd_rainfall(file_path, resolution, year, bbox = NULL)

Arguments

file_path

Path to the IMD NetCDF file (.nc).

resolution

Spatial resolution: 0.25 or 1.0.

year

Year of the data.

bbox

Optional named list or vector (north, south, east, west). If you set it, the function reads only that spatial slab from the disk (fast path). If NULL, the function reads the full grid.

Value

data.frame with columns: date, latitude, longitude, rainfall

Examples


f <- download_imd_rainfall(2023, 2023, resolution = 0.25)
rain_data <- read_imd_rainfall(f, 0.25, 2023)


varunayan documentation built on Oct. 30, 2026, 1:07 a.m.