clifro

:warning: ARCHIVED :warning: Easily download and visualise climate data from CliFlo

https://github.com/ropensci-archive/clifro

Science Score: 23.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
  • DOI references
  • Academic publication links
  • Committers with academic emails
    7 of 12 committers (58.3%) from academic institutions
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (15.9%) to scientific vocabulary

Keywords

climate-data climate-stations kml national-climate-database r r-package rstats weather windrose zealand

Keywords from Contributors

genome routes cycle ncbi-genbank proteome sequenced-genomes caching biodiversity gbif species
Last synced: 6 months ago · JSON representation

Repository

:warning: ARCHIVED :warning: Easily download and visualise climate data from CliFlo

Basic Info
  • Host: GitHub
  • Owner: ropensci-archive
  • Language: R
  • Default Branch: master
  • Homepage:
  • Size: 65.3 MB
Statistics
  • Stars: 26
  • Watchers: 7
  • Forks: 12
  • Open Issues: 0
  • Releases: 13
Archived
Topics
climate-data climate-stations kml national-climate-database r r-package rstats weather windrose zealand
Created almost 12 years ago · Last pushed about 1 year ago
Metadata Files
Readme Changelog Codemeta

README-not.md

Enhancing the National Climate Database with clifro

Build
Status CRAN\_Status\_Badge codecov.io Project Status: Active – The project has reached a stable, usable
state and is being actively
developed.

New Zealand’s National Climate Database, CliFlo holds data from about 6500 climate stations, with observations dating back to 1850. CliFlo returns raw data at ten minute, hourly, and daily frequencies. CliFlo also returns statistical summaries, inclusive of about eighty different types of monthly and annual statistics and six types of thirty−year normals.

The clifro package is designed to minimise the hassle in downloading data from CliFlo. It does this by providing functions for the user to log in, easily choose the appropriate datatypes and stations, and then query the database. Once the data have been downloaded, they are stored as specific objects in R with the primary aim to ensure data visualisation and exploration is done with minimal effort and maximum efficiency.

This package extends the functionality of CliFlo by returning stations resulting from simultaneous searches, the ability to visualise where these climate stations are by exporting to KML files, and elegant plotting of the climate data. The vignettes and help files are written with the intention that even inexperienced R users can use clifro easily. Exporting the climate data from R is fairly easy and for more experienced useRs, automated updating of spreadsheets or databases can be made much easier.

Free CliFlo Subscription

A current CliFlo subscription is recommended for clifro, otherwise data from only one station is available. The subscription is free and lasts for 2 years or 2,000,000 rows without renewal, which enables access to around 6,500 climate stations around New Zealand and the Pacific.

Note this package requires internet access for connecting to the National Climate Database web portal.

Installation in R

``` r

Install the latest CRAN release

install.packages("clifro")

Or the latest development version

if(!require(devtools)) install.packages("devtools") devtools::install_github("ropensci/clifro")

Then load the package

library(clifro) ```

Getting Started

The following small example shows some of the core functionality in clifro.

Where are the climate stations?

We can search for climate stations anywhere in New Zealand and return the station information in the form of a KML file. For example, we can return all the climate stations (current and historic) in the greater Auckland region.

r all.auckland.st = cf_find_station("Auckland", search = "region", status = "all") cf_save_kml(all.auckland.st, "all_auckland_stations")

All Auckland Climate Stations

Note the open stations have green markers and the closed stations have red markers.

Download and visualise public climate data

The only station available for unlimited public access to climate data is the Reefton electronic weather station (EWS). We can download the 2014 wind and rain data and easily visualise the results very easily.

``` r public.cfuser = cf_user()

Choose the datatypes

daily.wind.rain.dt = cf_datatype(c(2, 3), c(1, 1), list(4, 1), c(1, NA))

Choose the Reefton EWS station

reefton.st = cf_station()

Send the query to CliFlo and retrieve the data

daily.datalist = cfquery(user = public.cfuser, datatype = daily.wind.rain.dt, station = reefton.st, startdate = "2012-01-01 00", end_date = "2013-01-01 00")

> connecting to CliFlo...

> reading data...

> UserName is = public

> Number of charged rows output = 0

> Number of free rows output = 732

> Total number of rows output = 732

> Copyright NIWA 2020 Subject to NIWA's Terms and Conditions

> See: http://clifloecd1.niwa.co.nz/pls/niwp/doc/terms.html

> Comments to: cliflo@niwa.co.nz

Have a look at what data is now available

daily.datalist

> List containing clifro data frames:

> data type start end rows

> df 1) Surface Wind 9am only (2012-01-01 9:00) (2012-12-31 9:00) 366

> df 2) Rain Daily (2012-01-01 9:00) (2012-12-31 9:00) 366

Plot the data using default plotting methods

plot(daily.datalist) # For the first dataframe (Surface Wind) ```

r plot(daily.datalist, 2) # For the second dataframe (Rain)

For more details and reproducible examples, see the technical report for how to use clifro, including choosing datatypes, stations, saving locations as KML files and easy, elegant plotting for various different climate and weather data.

``` r

View the clifro demo

demo(clifro)

Read the 'Introduction to clifro' vignette

vignette("clifro") ```

Contributor Code of Conduct

The clifro package is released with a contributor code of conduct. By participating in this project you agree to abide by its terms.

Citation

``` bibtex

To cite package ‘clifro’ in publications use:

Seers B and Shears N (2015). “New Zealand's Climate Data in R - An Introduction to clifro.” The University of Auckland, Auckland, New Zealand. .

A BibTeX entry for LaTeX users is

@TechReport{, title = {New Zealand's Climate Data in R --- An Introduction to clifro}, author = {Blake Seers and Nick Shears}, institution = {The University of Auckland}, address = {Auckland, New Zealand}, year = {2015}, url = {https://stattech.wordpress.fos.auckland.ac.nz/2015/03/25/2015-02-new-zealands-climate-data-in-r-an-introduction-to-clifro/}, } ```

Owner

  • Name: rOpenSci Archive
  • Login: ropensci-archive
  • Kind: organization
  • Email: info@ropensci.org

Abandoned rOpenSci projects -- email info@ropensci.org if you have questions!

CodeMeta (codemeta.json)

{
  "@context": [
    "https://doi.org/doi:10.5063/schema/codemeta-2.0",
    "http://schema.org"
  ],
  "@type": "SoftwareSourceCode",
  "identifier": "clifro",
  "description": "CliFlo is a web portal to the New Zealand National Climate\n    Database and provides public access (via subscription) to around 6,500\n    various climate stations (see <https://cliflo.niwa.co.nz/> for more\n    information). Collating and manipulating data from CliFlo\n    (hence clifro) and importing into R for further analysis, exploration and\n    visualisation is now straightforward and coherent. The user is required to\n    have an internet connection, and a current CliFlo subscription (free) if\n    data from stations, other than the public Reefton electronic weather\n    station, is sought.",
  "name": "clifro: Easily Download and Visualise Climate Data from CliFlo",
  "codeRepository": "https://github.com/ropensci/clifro",
  "issueTracker": "https://github.com/ropensci/clifro/issues",
  "license": "https://spdx.org/licenses/GPL-2.0",
  "version": "3.2.3",
  "programmingLanguage": {
    "@type": "ComputerLanguage",
    "name": "R",
    "url": "https://r-project.org"
  },
  "runtimePlatform": "R version 4.0.2 (2020-06-22)",
  "provider": {
    "@id": "https://cran.r-project.org",
    "@type": "Organization",
    "name": "Central R Archive Network (CRAN)",
    "url": "https://cran.r-project.org"
  },
  "author": [
    {
      "@type": "Person",
      "givenName": "Blake",
      "familyName": "Seers",
      "email": "blake.seers@gmail.com",
      "@id": "http://orcid.org/0000-0001-6841-4312"
    }
  ],
  "maintainer": [
    {
      "@type": "Person",
      "givenName": "Blake",
      "familyName": "Seers",
      "email": "blake.seers@gmail.com",
      "@id": "http://orcid.org/0000-0001-6841-4312"
    }
  ],
  "softwareSuggestions": [
    {
      "@type": "SoftwareApplication",
      "identifier": "spelling",
      "name": "spelling",
      "provider": {
        "@id": "https://cran.r-project.org",
        "@type": "Organization",
        "name": "Comprehensive R Archive Network (CRAN)",
        "url": "https://cran.r-project.org"
      },
      "sameAs": "https://CRAN.R-project.org/package=spelling"
    },
    {
      "@type": "SoftwareApplication",
      "identifier": "knitr",
      "name": "knitr",
      "provider": {
        "@id": "https://cran.r-project.org",
        "@type": "Organization",
        "name": "Comprehensive R Archive Network (CRAN)",
        "url": "https://cran.r-project.org"
      },
      "sameAs": "https://CRAN.R-project.org/package=knitr"
    },
    {
      "@type": "SoftwareApplication",
      "identifier": "rmarkdown",
      "name": "rmarkdown",
      "provider": {
        "@id": "https://cran.r-project.org",
        "@type": "Organization",
        "name": "Comprehensive R Archive Network (CRAN)",
        "url": "https://cran.r-project.org"
      },
      "sameAs": "https://CRAN.R-project.org/package=rmarkdown"
    },
    {
      "@type": "SoftwareApplication",
      "identifier": "pander",
      "name": "pander",
      "provider": {
        "@id": "https://cran.r-project.org",
        "@type": "Organization",
        "name": "Comprehensive R Archive Network (CRAN)",
        "url": "https://cran.r-project.org"
      },
      "sameAs": "https://CRAN.R-project.org/package=pander"
    },
    {
      "@type": "SoftwareApplication",
      "identifier": "testthat",
      "name": "testthat",
      "provider": {
        "@id": "https://cran.r-project.org",
        "@type": "Organization",
        "name": "Comprehensive R Archive Network (CRAN)",
        "url": "https://cran.r-project.org"
      },
      "sameAs": "https://CRAN.R-project.org/package=testthat"
    }
  ],
  "softwareRequirements": [
    {
      "@type": "SoftwareApplication",
      "identifier": "methods",
      "name": "methods"
    },
    {
      "@type": "SoftwareApplication",
      "identifier": "lubridate",
      "name": "lubridate",
      "provider": {
        "@id": "https://cran.r-project.org",
        "@type": "Organization",
        "name": "Comprehensive R Archive Network (CRAN)",
        "url": "https://cran.r-project.org"
      },
      "sameAs": "https://CRAN.R-project.org/package=lubridate"
    },
    {
      "@type": "SoftwareApplication",
      "identifier": "xml2",
      "name": "xml2",
      "provider": {
        "@id": "https://cran.r-project.org",
        "@type": "Organization",
        "name": "Comprehensive R Archive Network (CRAN)",
        "url": "https://cran.r-project.org"
      },
      "sameAs": "https://CRAN.R-project.org/package=xml2"
    },
    {
      "@type": "SoftwareApplication",
      "identifier": "magrittr",
      "name": "magrittr",
      "provider": {
        "@id": "https://cran.r-project.org",
        "@type": "Organization",
        "name": "Comprehensive R Archive Network (CRAN)",
        "url": "https://cran.r-project.org"
      },
      "sameAs": "https://CRAN.R-project.org/package=magrittr"
    },
    {
      "@type": "SoftwareApplication",
      "identifier": "RCurl",
      "name": "RCurl",
      "provider": {
        "@id": "https://cran.r-project.org",
        "@type": "Organization",
        "name": "Comprehensive R Archive Network (CRAN)",
        "url": "https://cran.r-project.org"
      },
      "sameAs": "https://CRAN.R-project.org/package=RCurl"
    },
    {
      "@type": "SoftwareApplication",
      "identifier": "utils",
      "name": "utils"
    },
    {
      "@type": "SoftwareApplication",
      "identifier": "ggplot2",
      "name": "ggplot2",
      "version": ">= 2.0.0",
      "provider": {
        "@id": "https://cran.r-project.org",
        "@type": "Organization",
        "name": "Comprehensive R Archive Network (CRAN)",
        "url": "https://cran.r-project.org"
      },
      "sameAs": "https://CRAN.R-project.org/package=ggplot2"
    },
    {
      "@type": "SoftwareApplication",
      "identifier": "scales",
      "name": "scales",
      "provider": {
        "@id": "https://cran.r-project.org",
        "@type": "Organization",
        "name": "Comprehensive R Archive Network (CRAN)",
        "url": "https://cran.r-project.org"
      },
      "sameAs": "https://CRAN.R-project.org/package=scales"
    },
    {
      "@type": "SoftwareApplication",
      "identifier": "RColorBrewer",
      "name": "RColorBrewer",
      "provider": {
        "@id": "https://cran.r-project.org",
        "@type": "Organization",
        "name": "Comprehensive R Archive Network (CRAN)",
        "url": "https://cran.r-project.org"
      },
      "sameAs": "https://CRAN.R-project.org/package=RColorBrewer"
    },
    {
      "@type": "SoftwareApplication",
      "identifier": "reshape2",
      "name": "reshape2",
      "provider": {
        "@id": "https://cran.r-project.org",
        "@type": "Organization",
        "name": "Comprehensive R Archive Network (CRAN)",
        "url": "https://cran.r-project.org"
      },
      "sameAs": "https://CRAN.R-project.org/package=reshape2"
    },
    {
      "@type": "SoftwareApplication",
      "identifier": "rvest",
      "name": "rvest",
      "provider": {
        "@id": "https://cran.r-project.org",
        "@type": "Organization",
        "name": "Comprehensive R Archive Network (CRAN)",
        "url": "https://cran.r-project.org"
      },
      "sameAs": "https://CRAN.R-project.org/package=rvest"
    }
  ],
  "applicationCategory": "DataAccess",
  "keywords": [
    "r",
    "opensci",
    "zealand",
    "weather",
    "climate",
    "cliflo",
    "data",
    "api",
    "windrose",
    "rain",
    "wind",
    "temperature",
    "climate-data",
    "climate-stations",
    "national-climate-database",
    "kml",
    "rstats",
    "r-package"
  ],
  "isPartOf": "\"https://ropensci.org\"",
  "contIntegration": [
    "https://travis-ci.org/ropensci/clifro",
    "https://codecov.io/github/ropensci/clifro?branch=master"
  ],
  "releaseNotes": "https://github.com/ropensci/clifro/blob/master/NEWS.md",
  "readme": "https://github.com/ropensci/clifro/blob/master/README.md",
  "fileSize": "2398.08KB",
  "citation": [
    {
      "datePublished": "2015",
      "author": [
        {
          "@type": "Person",
          "givenName": "Blake",
          "familyName": "Seers"
        },
        {
          "@type": "Person",
          "givenName": "Nick",
          "familyName": "Shears"
        }
      ],
      "name": "New Zealand's Climate Data in R --- An Introduction to clifro",
      "url": "http://stattech.wordpress.fos.auckland.ac.nz/2015-02-new-zealands-climate-data-in-r-an-introduction-to-clifro/"
    }
  ],
  "contributor": {},
  "copyrightHolder": {},
  "funder": {},
  "relatedLink": [
    "https://CRAN.R-project.org/package=clifro",
    "https://docs.ropensci.org/clifro/"
  ],
  "developmentStatus": "https://www.repostatus.org/#active"
}

GitHub Events

Total
Last Year

Committers

Last synced: 6 months ago

All Time
  • Total Commits: 253
  • Total Committers: 12
  • Avg Commits per committer: 21.083
  • Development Distribution Score (DDS): 0.328
Past Year
  • Commits: 2
  • Committers: 1
  • Avg Commits per committer: 2.0
  • Development Distribution Score (DDS): 0.0
Top Committers
Name Email Commits
blasee b****s@g****m 170
Seers s****4@c****u 29
steven2249 s****w@b****u 26
Blake Seers B****s@C****u 12
Simon Potter s****n@s****z 6
Maëlle Salmon m****n@y****e 2
Chris Fan c****n@b****u 2
Seers, Blake (Environment, Aspendale) B****s@c****u 2
katieroserice k****e@b****u 1
Scott Chamberlain m****s@g****m 1
ropenscibot m****t@g****m 1
Blake Seers s****4@s****u 1
Committer Domains (Top 20 + Academic)

Issues and Pull Requests

Last synced: 6 months ago

All Time
  • Total issues: 24
  • Total pull requests: 9
  • Average time to close issues: about 2 months
  • Average time to close pull requests: 2 days
  • Total issue authors: 19
  • Total pull request authors: 6
  • Average comments per issue: 3.63
  • Average comments per pull request: 2.33
  • Merged pull requests: 8
  • Bot issues: 0
  • Bot pull requests: 0
Past Year
  • Issues: 0
  • Pull requests: 0
  • Average time to close issues: N/A
  • Average time to close pull requests: N/A
  • Issue authors: 0
  • Pull request authors: 0
  • Average comments per issue: 0
  • Average comments per pull request: 0
  • Merged pull requests: 0
  • Bot issues: 0
  • Bot pull requests: 0
Top Authors
Issue Authors
  • blasee (4)
  • sckott (3)
  • moreron (1)
  • linleyj (1)
  • rgommers (1)
  • James-Hogan (1)
  • adamhsparks (1)
  • nevermana-landcare (1)
  • gis-maker (1)
  • swmpkim (1)
  • ldatamine (1)
  • HaizhenWu (1)
  • bonopo (1)
  • markbneal (1)
  • frank0434 (1)
Pull Request Authors
  • katieroserice (2)
  • stevenysw (2)
  • blasee (2)
  • chrisfan24 (1)
  • sjp (1)
  • sckott (1)
Top Labels
Issue Labels
bug (1) enhancement (1)
Pull Request Labels

Dependencies

DESCRIPTION cran
  • RColorBrewer * imports
  • ggplot2 >= 2.0.0 imports
  • graphics * imports
  • httr * imports
  • lubridate * imports
  • magrittr * imports
  • methods * imports
  • reshape2 * imports
  • rvest * imports
  • scales * imports
  • stats * imports
  • stringr * imports
  • utils * imports
  • xml2 * imports
  • knitr * suggests
  • pander * suggests
  • rmarkdown * suggests
  • spelling * suggests
  • testthat * suggests