Giter VIP home page Giter VIP logo

helsinki's Introduction

helsinki - Helsinki open data R tools

rOG-badge R build status CRAN Status Badge Downloads total Downloads monthly Watch on GitHub Star on GitHub Follow on Twitter

The goal of helsinki package is to provide tools in R to access and download open data from City of Helsinki and the Helsinki metropolitan area - the Finnish capital region.

Installation

You can install the released version of helsinki from CRAN with:

install.packages("helsinki")

And the development version from GitHub with:

# install.packages("remotes)
library(remotes)
remotes::install_github("ropengov/helsinki")

Using the package

Loading the package:

library(helsinki)

List available features from Helsinki Region Environmental Services HSY WFS API and then download the 15th feature from that list:

url <- "https://kartta.hsy.fi/geoserver/wfs"
hsy_features <- get_feature_list(base.url = url)
get_feature(base.url = url, typename = hsy_features$Name[15])

For more examples, check the tutorial page.

Contributing

You are welcome to contact us:

Acknowledgements

Kindly cite this work as follows: Juuso Parkkinen, Joona Lehtomäki, Pyry Kantanen, and Leo Lahti. helsinki - Helsinki open data R tools. URL: http://ropengov.github.io/helsinki/

Alternatively, run citation("helsinki") in your R environment after installing this package or see the “Cite this repository” section of the package’s GitHub repository.

We are grateful to all contributors! This project is part of rOpenGov.

helsinki's People

Contributors

actions-user avatar antagomir avatar github-actions[bot] avatar ouzor avatar pitkant avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

helsinki's Issues

Travis CI to GitHub Actions

Old Travis-CI.org service will be shut down after 31th of December, requiring either action to migrate to the commercial Travis-CI.com service or migrating to a new CI altogether. An rOpenSci blogpost describes the pros of moving to GitHub Actions. The process is as follows:

  1. run: usethis::use_github_action_check_standard()
  2. Check if package tests contain skip_on_travis -functions and replace them with skip_on_ci
  3. Add a badge to the package README: [![R build status](https://github.com/rOpenGov/PACKAGENAME/workflows/R-CMD-check/badge.svg)](https://github.com/rOpenGov/PACKAGENAME/actions)
  4. Remove Travis CI badge (and Appveyor badge as well, since GHA runs tests simultaneously for Linux, macOS and Windows)

Branch protection rules interfere with GitHub Actions

  • @ouzor implemented branch protection rules for master branch on 6.12.2022
  • However, the requirement of making a PR first and getting reviews caused the following error message when changes to README.md were to be committed:

remote: error: GH006: Protected branch update failed for refs/heads/master.
remote: error: At least 1 approving review is required by reviewers with write access.
To https://github.com/rOpenGov/helsinki
! [remote rejected] master -> master (protected branch hook declined)
error: failed to push some refs to 'https://github.com/rOpenGov/helsinki'
No changes to commit

  • Consequently I removed the branch protection rule to get the Github action working.
  • There is a GitHub Community discussion going on since 10.10.2019 about this very issue.
  • We can of course always ask whether having a separate action for rebuilding the README.md file is efficient use of computational resources and whether this should be done locally.
  • OR we can discuss on other ways on how to protect the master branch.

(Peter Evans' answer on SO was something I tried to utilise when finding ways to fix this problem but apparently it was no panacea for this specific configuration of protected branch)

Render README fails

Render README workflow fails (for example on 616a25d) with the following error: "Failed to build source package 's2' "

I'll continue monitoring if this is a temporary hiccup or perhaps related to the platform on which this workflow runs: macOS-latest

Fix keywords

Keywords are currently uninformative, either remove or improve

get_hsy() is broken

HSY open data pages have been updated, need to update get_hsy() correspondingly!

Fix examples

From Prof. Ripley:
"Those parts of examples enclosed in \donttest{} are run by examples() and so must be valid R code. This is now checked by R-devel, and the CRAN results pages for your packages show WARNINGs because some of your code is invalid.

Please submit a corrected update checked with current R-devel (note that the check stops at the first error: there may be more) as soon as possible.

There may be other issues showing on the check pages which should also be addressed."

Simplify vignette

Current vignette is rather heavy and has produced several errors on CRAN.
@pitkant suggested simplifying the package vignette, and publishing the longer version as a blog post / article. I think this makes sense.

get_servicemap() should fail gracefully

Ripley emailed:

Please see the problems shown on
https://cran.r-project.org/web/checks/check_results_helsinki.html.

Please correct before 2022-12-04 to safely retain your package on CRAN.

It seems we need to remind you of the CRAN policy:

'Packages which use Internet resources should fail gracefully with an informative message
if the resource is not available or has changed (and not give a check warning nor error).'

This needs correction whether or not the resource recovers.

Implement wrappers for gisfin functions

Note that gisfin has to be in CRAN first.
Implement a wrapper for gisfin::get_helsinki_spatial(), imports gisfin.
Additionally think about moving get_hsy() to gisfin and implementing a wrapper, as it is spatial data as well.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.