Skip to contents

Fetch the BOM daily Coastal Waters Forecast and return a data frame of the forecast regions for a specified state or region.

Usage

get_coastal_forecast(state = "AUS")

Arguments

state

Australian state or territory as full name or postal code. Fuzzy string matching via agrep is done. Defaults to “AUS” returning all state forecasts, see details for further information.

Value

A data.table of an Australia BOMCoastal Waters Forecast. For full details of fields and units returned see Appendix 5 in the bomrang vignette, use
vignette("bomrang", package = "bomrang") to view.

Details

Allowed state and territory postal codes, only one state per request or all using AUS.

ACT

Australian Capital Territory (will return NSW)

NSW

New South Wales

NT

Northern Territory

QLD

Queensland

SA

South Australia

TAS

Tasmania

VIC

Victoria

WA

Western Australia

AUS

Australia, returns forecast for all states, NT and ACT

References

Forecast data come from Australian Bureau of Meteorology (BOM) Weather Data Services
http://www.bom.gov.au/catalogue/data-feeds.shtml

Location data and other metadata come from the BOM anonymous FTP server with spatial data
ftp://ftp.bom.gov.au/anon/home/adfd/spatial/, specifically the DBF file portion of a shapefile,
ftp://ftp.bom.gov.au/anon/home/adfd/spatial/IDM00003.dbf

Author

Dean Marchiori, [email protected] and Paul Melloy [email protected]

Examples

# \donttest{
coastal_forecast <- get_coastal_forecast(state = "NSW")
coastal_forecast
#>     index product_id type state_code
#>  1:  <NA>   IDN11001 <NA>        NSW
#>  2:     0   IDN11001 <NA>        NSW
#>  3:     1   IDN11001 <NA>        NSW
#>  4:     2   IDN11001 <NA>        NSW
#>  5:     0   IDN11001 <NA>        NSW
#>  6:     1   IDN11001 <NA>        NSW
#>  7:     2   IDN11001 <NA>        NSW
#>  8:     0   IDN11001 <NA>        NSW
#>  9:     1   IDN11001 <NA>        NSW
#> 10:     2   IDN11001 <NA>        NSW
#> 11:     0   IDN11001 <NA>        NSW
#> 12:     1   IDN11001 <NA>        NSW
#> 13:     2   IDN11001 <NA>        NSW
#> 14:     0   IDN11001 <NA>        NSW
#> 15:     1   IDN11001 <NA>        NSW
#> 16:     2   IDN11001 <NA>        NSW
#> 17:     0   IDN11001 <NA>        NSW
#> 18:     1   IDN11001 <NA>        NSW
#> 19:     2   IDN11001 <NA>        NSW
#> 20:     0   IDN11001 <NA>        NSW
#> 21:     1   IDN11001 <NA>        NSW
#> 22:     2   IDN11001 <NA>        NSW
#> 23:     0   IDN11001 <NA>        NSW
#> 24:     1   IDN11001 <NA>        NSW
#> 25:     2   IDN11001 <NA>        NSW
#>     index product_id type state_code
#>                                        dist_name pt_1_name pt_2_name       aac
#>  1:                              New South Wales      <NA>      <NA> NSW_FA001
#>  2:   Eden Coast: Montague Island to Gabo Island      <NA>      <NA> NSW_MW001
#>  3:   Eden Coast: Montague Island to Gabo Island      <NA>      <NA> NSW_MW001
#>  4:   Eden Coast: Montague Island to Gabo Island      <NA>      <NA> NSW_MW001
#>  5: Batemans Coast: Ulladulla to Montague Island      <NA>      <NA> NSW_MW002
#>  6: Batemans Coast: Ulladulla to Montague Island      <NA>      <NA> NSW_MW002
#>  7: Batemans Coast: Ulladulla to Montague Island      <NA>      <NA> NSW_MW002
#>  8:   Illawarra Coast: Port Hacking to Ulladulla      <NA>      <NA> NSW_MW003
#>  9:   Illawarra Coast: Port Hacking to Ulladulla      <NA>      <NA> NSW_MW003
#> 10:   Illawarra Coast: Port Hacking to Ulladulla      <NA>      <NA> NSW_MW003
#> 11:     Sydney Coast: Broken Bay to Port Hacking      <NA>      <NA> NSW_MW004
#> 12:     Sydney Coast: Broken Bay to Port Hacking      <NA>      <NA> NSW_MW004
#> 13:     Sydney Coast: Broken Bay to Port Hacking      <NA>      <NA> NSW_MW004
#> 14:       Hunter Coast: Seal Rocks to Broken Bay      <NA>      <NA> NSW_MW005
#> 15:       Hunter Coast: Seal Rocks to Broken Bay      <NA>      <NA> NSW_MW005
#> 16:       Hunter Coast: Seal Rocks to Broken Bay      <NA>      <NA> NSW_MW005
#> 17:    Macquarie Coast: Smoky Cape to Seal Rocks      <NA>      <NA> NSW_MW006
#> 18:    Macquarie Coast: Smoky Cape to Seal Rocks      <NA>      <NA> NSW_MW006
#> 19:    Macquarie Coast: Smoky Cape to Seal Rocks      <NA>      <NA> NSW_MW006
#> 20:             Coffs Coast: Wooli to Smoky Cape      <NA>      <NA> NSW_MW007
#> 21:             Coffs Coast: Wooli to Smoky Cape      <NA>      <NA> NSW_MW007
#> 22:             Coffs Coast: Wooli to Smoky Cape      <NA>      <NA> NSW_MW007
#> 23:           Byron Coast: Point Danger to Wooli      <NA>      <NA> NSW_MW008
#> 24:           Byron Coast: Point Danger to Wooli      <NA>      <NA> NSW_MW008
#> 25:           Byron Coast: Point Danger to Wooli      <NA>      <NA> NSW_MW008
#>                                        dist_name pt_1_name pt_2_name       aac
#>        start_time_local      end_time_local utc_offset      start_time_utc
#>  1: 2022-06-02 10:00:48 2022-06-02 10:00:48      10:00 2022-06-02 10:00:48
#>  2: 2022-06-02 10:00:00 2022-06-02 10:00:00      10:00 2022-06-02 10:00:00
#>  3: 2022-06-03 00:00:00 2022-06-03 00:00:00      10:00 2022-06-03 00:00:00
#>  4: 2022-06-04 00:00:00 2022-06-04 00:00:00      10:00 2022-06-04 00:00:00
#>  5: 2022-06-02 10:00:00 2022-06-02 10:00:00      10:00 2022-06-02 10:00:00
#>  6: 2022-06-03 00:00:00 2022-06-03 00:00:00      10:00 2022-06-03 00:00:00
#>  7: 2022-06-04 00:00:00 2022-06-04 00:00:00      10:00 2022-06-04 00:00:00
#>  8: 2022-06-02 10:00:00 2022-06-02 10:00:00      10:00 2022-06-02 10:00:00
#>  9: 2022-06-03 00:00:00 2022-06-03 00:00:00      10:00 2022-06-03 00:00:00
#> 10: 2022-06-04 00:00:00 2022-06-04 00:00:00      10:00 2022-06-04 00:00:00
#> 11: 2022-06-02 10:00:00 2022-06-02 10:00:00      10:00 2022-06-02 10:00:00
#> 12: 2022-06-03 00:00:00 2022-06-03 00:00:00      10:00 2022-06-03 00:00:00
#> 13: 2022-06-04 00:00:00 2022-06-04 00:00:00      10:00 2022-06-04 00:00:00
#> 14: 2022-06-02 10:00:00 2022-06-02 10:00:00      10:00 2022-06-02 10:00:00
#> 15: 2022-06-03 00:00:00 2022-06-03 00:00:00      10:00 2022-06-03 00:00:00
#> 16: 2022-06-04 00:00:00 2022-06-04 00:00:00      10:00 2022-06-04 00:00:00
#> 17: 2022-06-02 10:00:00 2022-06-02 10:00:00      10:00 2022-06-02 10:00:00
#> 18: 2022-06-03 00:00:00 2022-06-03 00:00:00      10:00 2022-06-03 00:00:00
#> 19: 2022-06-04 00:00:00 2022-06-04 00:00:00      10:00 2022-06-04 00:00:00
#> 20: 2022-06-02 10:00:00 2022-06-02 10:00:00      10:00 2022-06-02 10:00:00
#> 21: 2022-06-03 00:00:00 2022-06-03 00:00:00      10:00 2022-06-03 00:00:00
#> 22: 2022-06-04 00:00:00 2022-06-04 00:00:00      10:00 2022-06-04 00:00:00
#> 23: 2022-06-02 05:00:00 2022-06-02 05:00:00      10:00 2022-06-02 05:00:00
#> 24: 2022-06-03 00:00:00 2022-06-03 00:00:00      10:00 2022-06-03 00:00:00
#> 25: 2022-06-04 00:00:00 2022-06-04 00:00:00      10:00 2022-06-04 00:00:00
#>        start_time_local      end_time_local utc_offset      start_time_utc
#>            end_time_utc
#>  1: 2022-06-02 10:00:48
#>  2: 2022-06-02 10:00:00
#>  3: 2022-06-03 00:00:00
#>  4: 2022-06-04 00:00:00
#>  5: 2022-06-02 10:00:00
#>  6: 2022-06-03 00:00:00
#>  7: 2022-06-04 00:00:00
#>  8: 2022-06-02 10:00:00
#>  9: 2022-06-03 00:00:00
#> 10: 2022-06-04 00:00:00
#> 11: 2022-06-02 10:00:00
#> 12: 2022-06-03 00:00:00
#> 13: 2022-06-04 00:00:00
#> 14: 2022-06-02 10:00:00
#> 15: 2022-06-03 00:00:00
#> 16: 2022-06-04 00:00:00
#> 17: 2022-06-02 10:00:00
#> 18: 2022-06-03 00:00:00
#> 19: 2022-06-04 00:00:00
#> 20: 2022-06-02 10:00:00
#> 21: 2022-06-03 00:00:00
#> 22: 2022-06-04 00:00:00
#> 23: 2022-06-02 05:00:00
#> 24: 2022-06-03 00:00:00
#> 25: 2022-06-04 00:00:00
#>            end_time_utc
#>                                                                                                        forecast_seas
#>  1:                                                                                                             <NA>
#>  2:                                                           1 to 2 metres, decreasing to 1 metre by early evening.
#>  3: Below 1 metre, increasing to 1 to 1.5 metres during the morning, then decreasing below 1 metre by early evening.
#>  4:                                        Below 1 metre, increasing to 1 to 1.5 metres offshore during the evening.
#>  5:                                                        1 to 2 metres, decreasing below 1 metre by early evening.
#>  6:                      Around 1 metre, increasing to 1 to 1.5 metres offshore north of Moruya Heads around midday.
#>  7:                                                            Around 1 metre, increasing to 1 to 2 metres offshore.
#>  8:                                                        1 to 2 metres, decreasing below 1 metre by early evening.
#>  9:                                            Around 1 metre, increasing to 1 to 1.5 metres offshore around midday.
#> 10:                                    1 to 1.5 metres, increasing to 1.5 to 2 metres offshore south of Port Kembla.
#> 11:                                                        1 to 2 metres, decreasing below 1 metre by early evening.
#> 12:                                             Below 1 metre, increasing to 1 to 1.5 metres offshore around midday.
#> 13:                                                          Around 1 metre, increasing to 1 to 1.5 metres offshore.
#> 14:                                                       1.5 to 2.5 metres, decreasing to 1 metre by early evening.
#> 15:                        Around 1 metre, increasing to 1 to 1.5 metres offshore south of Norah Head around midday.
#> 16:                                       1 to 1.5 metres, increasing to 1 to 2 metres offshore north of Norah Head.
#> 17:                                                           1 to 2 metres, decreasing to 1 metre by early evening.
#> 18:                                              Around 1 metre, increasing to 1 to 2 metres offshore around midday.
#> 19:                                    1 to 2 metres, decreasing to 1 to 1.5 metres during the afternoon or evening.
#> 20:                                                      1 to 1.5 metres, decreasing below 1 metre by early evening.
#> 21:                                                        Below 1 metre, increasing to 1 to 2 metres around midday.
#> 22:                                                       1 to 2 metres, decreasing to 1 metre during the afternoon.
#> 23:                                                  1 to 1.5 metres, decreasing below 1 metre during the afternoon.
#> 24:                                         Around 1 metre, increasing to 1 to 1.5 metres offshore by early evening.
#> 25:                                              1.5 to 2.5 metres, decreasing to 1 metre during the late afternoon.
#>                                                                                                        forecast_seas
#>                                                               forecast_weather
#>  1:                                                                       <NA>
#>  2:                                                             Partly cloudy.
#>  3:                                                                    Cloudy.
#>  4:                                                             Partly cloudy.
#>  5:                                                             Partly cloudy.
#>  6:                                                                    Cloudy.
#>  7:                                                              Mostly sunny.
#>  8: Partly cloudy. 50% chance of showers offshore, near zero chance elsewhere.
#>  9:                       Partly cloudy. 60% chance of showers in the evening.
#> 10:                                                             Partly cloudy.
#> 11: Partly cloudy. 50% chance of showers offshore, near zero chance elsewhere.
#> 12:                       Partly cloudy. 70% chance of showers in the evening.
#> 13:                                                             Partly cloudy.
#> 14: Partly cloudy. 50% chance of showers offshore, near zero chance elsewhere.
#> 15:                       Partly cloudy. 80% chance of showers in the evening.
#> 16:                                      Partly cloudy. 50% chance of showers.
#> 17:                                                             Partly cloudy.
#> 18:                                      Partly cloudy. 80% chance of showers.
#> 19:                                      Partly cloudy. 50% chance of showers.
#> 20:                                                             Partly cloudy.
#> 21:                                      Partly cloudy. 90% chance of showers.
#> 22:                                      Partly cloudy. 50% chance of showers.
#> 23:                                                             Partly cloudy.
#> 24:                                      Partly cloudy. 80% chance of showers.
#> 25:                                      Partly cloudy. 70% chance of showers.
#>                                                               forecast_weather
#>                                                                                                                                                                     forecast_winds
#>  1:                                                                                                                                                                           <NA>
#>  2:                                                Southwesterly 15 to 25 knots, easing to 10 to 15 knots in the afternoon. Winds becoming variable about 10 knots in the evening.
#>  3:                                    Northerly 10 to 15 knots increasing to 15 to 20 knots during the morning. Winds tending west to northwesterly in the afternoon and evening.
#>  4:                                                                                                         Westerly 10 to 15 knots turning northwesterly 15 to 25 knots offshore.
#>  5:                                                   Southwesterly 15 to 25 knots, easing to 10 to 15 knots in the afternoon and becoming variable about 10 knots in the evening.
#>  6:                                                                             North to northwesterly 10 to 15 knots tending west to northwesterly 15 to 20 knots during the day.
#>  7:                                                                                          West to northwesterly 15 to 25 knots increasing to 20 to 30 knots during the evening.
#>  8:                                                                                           Southwesterly 15 to 25 knots. Winds becoming variable about 10 knots in the evening.
#>  9:                                                                           North to northwesterly 10 to 15 knots tending west to northwesterly 15 to 20 knots in the afternoon.
#> 10:                                                                                                      Westerly 15 to 25 knots, winds reaching up to 30 knots offshore at times.
#> 11:                                Southwesterly 15 to 25 knots. Winds decreasing to 10 to 15 knots in the middle of the day then becoming variable below 10 knots in the evening.
#> 12:                                                  Northwesterly about 10 knots increasing to 15 to 20 knots in the morning and becoming westerly 15 to 25 knots in the evening.
#> 13:                                                                                               Northwesterly 15 to 20 knots tending westerly 15 to 25 knots during the morning.
#> 14:                Southwesterly 15 to 20 knots, reaching up to 30 knots offshore north of Norah Head in the late morning. Winds decreasing to about 10 knots in the late evening.
#> 15:                             Northwesterly about 10 knots increasing to 10 to 15 knots in the morning. Winds reaching up to 20 knots offshore during the afternoon and evening.
#> 16:                                                                                                                                                       Westerly 20 to 30 knots.
#> 17:               Southwesterly 15 to 20 knots, reaching up to 25 knots offshore south of Crowdy Head in the late morning. Winds decreasing to about 10 knots in the late evening.
#> 18: West to northwesterly about 10 knots tending north to northwesterly 15 to 20 knots in the morning. Winds reaching up to 30 knots offshore north of Crowdy Head in the evening.
#> 19:                                                                                  Northwesterly 15 to 20 knots turning west to southwesterly 15 to 25 knots during the morning.
#> 20:                         Southwesterly 10 to 20 knots tending southerly 10 to 15 knots in the early afternoon then turning west to southwesterly below 10 knots in the evening.
#> 21:           West to northwesterly about 10 knots tending north to northwesterly 15 to 20 knots early in the morning. Winds reaching up to 30 knots offshore in the late evening.
#> 22:                                                                                  Northwesterly 20 to 30 knots turning west to southwesterly 10 to 15 knots during the morning.
#> 23:                                                                                      South to southwesterly 15 to 25 knots decreasing to about 10 knots in the late afternoon.
#> 24:                                                                                              Variable about 10 knots becoming northerly 15 to 20 knots in the early afternoon.
#> 25:                                                        North to northwesterly 20 to 25 knots increasing to 30 knots before turning westerly 15 to 25 knots during the morning.
#>                                                                                                                                                                     forecast_winds
#>                                                                               forecast_swell1
#>  1:                                                                                      <NA>
#>  2:                                                                  Southerly 2 to 3 metres.
#>  3:                          Southerly 2.5 to 3 metres, decreasing to 2 metres around midday.
#>  4: South to southeasterly 1.5 to 2 metres, decreasing to 1 to 1.5 metres during the morning.
#>  5:                                                                Southerly 2 to 2.5 metres.
#>  6:                     Southerly 2 to 3 metres, decreasing to 2 metres during the afternoon.
#>  7:                     Southerly 2 metres, decreasing to 1 to 1.5 metres during the morning.
#>  8:                                                                Southerly 2 to 2.5 metres.
#>  9:                                                                Southerly 2 to 2.5 metres.
#> 10:                          Southerly 2 metres, decreasing to 1.5 metres during the morning.
#> 11:                                                                Southerly 2.5 to 3 metres.
#> 12:                                                                Southerly 2 to 2.5 metres.
#> 13:                          Southerly 2 metres, decreasing to 1.5 metres during the morning.
#> 14:                                                                  Southerly 2 to 3 metres.
#> 15:                     Southerly 2 to 3 metres, decreasing to 2 metres later in the evening.
#> 16:                   Southerly 1.5 to 2 metres, decreasing to 1.5 metres during the morning.
#> 17:                                                                  Southerly 2 to 3 metres.
#> 18:                                                                Southerly 2 to 2.5 metres.
#> 19:                   Southerly 1.5 to 2 metres, decreasing to 1.5 metres during the morning.
#> 20:                  Southerly 1.5 to 2 metres inshore, increasing to 2 to 3 metres offshore.
#> 21:                                                                Southerly 2 to 2.5 metres.
#> 22:                          Southerly 2 metres, decreasing to 1.5 metres during the morning.
#> 23:                    Southerly 1 to 2 metres inshore, increasing to 2 to 3 metres offshore.
#> 24:                                                              Southerly 1.5 to 2.5 metres.
#> 25:                 Southerly 1.5 to 2 metres, decreasing to 1.5 metres during the afternoon.
#>                                                                               forecast_swell1
#>     forecast_swell2
#>  1:            <NA>
#>  2:            <NA>
#>  3:            <NA>
#>  4:            <NA>
#>  5:            <NA>
#>  6:            <NA>
#>  7:            <NA>
#>  8:            <NA>
#>  9:            <NA>
#> 10:            <NA>
#> 11:            <NA>
#> 12:            <NA>
#> 13:            <NA>
#> 14:            <NA>
#> 15:            <NA>
#> 16:            <NA>
#> 17:            <NA>
#> 18:            <NA>
#> 19:            <NA>
#> 20:            <NA>
#> 21:            <NA>
#> 22:            <NA>
#> 23:            <NA>
#> 24:            <NA>
#> 25:            <NA>
#>     forecast_swell2
#>                                                                                                                                                  forecast_caution
#>  1:                                                                                                                                                          <NA>
#>  2:                                                                                                                                                          <NA>
#>  3:                                                                                                                                                          <NA>
#>  4:                                                                                                                                                          <NA>
#>  5:                                                                                                                                                          <NA>
#>  6: Surf conditions may be more powerful than they appear and are expected to be hazardous for coastal activities such as crossing bars by boat and rock fishing.
#>  7:                                                                                                                                                          <NA>
#>  8: Surf conditions may be more powerful than they appear and are expected to be hazardous for coastal activities such as crossing bars by boat and rock fishing.
#>  9: Surf conditions may be more powerful than they appear and are expected to be hazardous for coastal activities such as crossing bars by boat and rock fishing.
#> 10:                                                                                                                                                          <NA>
#> 11: Surf conditions may be more powerful than they appear and are expected to be hazardous for coastal activities such as crossing bars by boat and rock fishing.
#> 12: Surf conditions may be more powerful than they appear and are expected to be hazardous for coastal activities such as crossing bars by boat and rock fishing.
#> 13:                                                                                                                                                          <NA>
#> 14: Surf conditions may be more powerful than they appear and are expected to be hazardous for coastal activities such as crossing bars by boat and rock fishing.
#> 15: Surf conditions may be more powerful than they appear and are expected to be hazardous for coastal activities such as crossing bars by boat and rock fishing.
#> 16:                                                                                                                                                          <NA>
#> 17: Surf conditions may be more powerful than they appear and are expected to be hazardous for coastal activities such as crossing bars by boat and rock fishing.
#> 18: Surf conditions may be more powerful than they appear and are expected to be hazardous for coastal activities such as crossing bars by boat and rock fishing.
#> 19:                                                                                                                                                          <NA>
#> 20:                                                                                                                                                          <NA>
#> 21:                                                                                                                                                          <NA>
#> 22:                                                                                                                                                          <NA>
#> 23:                                                                                                                                                          <NA>
#> 24:                                                                                                                                                          <NA>
#> 25:                                                                                                                                                          <NA>
#>                                                                                                                                                  forecast_caution
#>                                        marine_forecast tropical_system_location
#>  1:                                               <NA>                       NA
#>  2:                                               <NA>                       NA
#>  3:                                               <NA>                       NA
#>  4:                                               <NA>                       NA
#>  5:                                               <NA>                       NA
#>  6:                                               <NA>                       NA
#>  7:                                               <NA>                       NA
#>  8:                                               <NA>                       NA
#>  9:                                               <NA>                       NA
#> 10:                                               <NA>                       NA
#> 11:                                               <NA>                       NA
#> 12:                                               <NA>                       NA
#> 13:                                               <NA>                       NA
#> 14:  Strong Wind Warning for Thursday for Hunter Coast                       NA
#> 15:                                               <NA>                       NA
#> 16:                                               <NA>                       NA
#> 17:                                               <NA>                       NA
#> 18: Strong Wind Warning for Friday for Macquarie Coast                       NA
#> 19:                                               <NA>                       NA
#> 20:                                               <NA>                       NA
#> 21:     Strong Wind Warning for Friday for Coffs Coast                       NA
#> 22:                                               <NA>                       NA
#> 23:                                               <NA>                       NA
#> 24:                                               <NA>                       NA
#> 25:                                               <NA>                       NA
#>                                        marine_forecast tropical_system_location
#>     forecast_waves
#>  1:             NA
#>  2:             NA
#>  3:             NA
#>  4:             NA
#>  5:             NA
#>  6:             NA
#>  7:             NA
#>  8:             NA
#>  9:             NA
#> 10:             NA
#> 11:             NA
#> 12:             NA
#> 13:             NA
#> 14:             NA
#> 15:             NA
#> 16:             NA
#> 17:             NA
#> 18:             NA
#> 19:             NA
#> 20:             NA
#> 21:             NA
#> 22:             NA
#> 23:             NA
#> 24:             NA
#> 25:             NA
#>     forecast_waves
# }