Skip to content
/ fmi Public
forked from rOpenGov/fmi

Finnish Meteorological Institute open data API R client

License

Notifications You must be signed in to change notification settings

mecwes/fmi

 
 

Repository files navigation

Finnish Meteorological Institute (FMI) open data API client for R

Build Status Stories in Ready Join the chat at https://gitter.im/rOpenGov/fmi codecov

This R package (fmi) provides a client to access the Finnish Meteorological Institute (Ilmatieteenlaitos) open data. This R package is a part of the rOpenGov project.

Overview

This R package provides tools to access open data from Finnish Meteorological Institute (Ilmatieteenlaitos).

This R package is part of the rOpenGov project.

Usage

For usage, check the tutorial page. Also check these examples of getting FMI lightning data and gridded observation (raster) data.

Installation

Libraries

The fmi package depends on the GDAL library and its command line tools, and on rgdal package. If you have GDAL already installed, you might need to update it to newer version. Also, add the command line tools to the search path of your system. Below you can find some instructions on how to do these tasks on different platforms.

For rgdal package, please, see additional installation instructions in the gisfin package tutorial.

Linux

Installing GDAL:

Install gdal / gdal-devel packages using your Linux distibution's package manager. See here on some pointers on where to find suitable binaries.

Adding GDAL command line tools to your path

In Linux, the tools should be found from the path by default after installation. If not, use the export command from terminal, for example:

export PATH=$PATH:/usr/local/gdal/bin

OS X

Installing GDAL:

See here.

Adding GDAL command line tools to your path

From terminal, type:

export PATH=$PATH:/Library/Frameworks/GDAL.framework/Programs

Windows

Installing GDAL:

For installing GDAL the easy way see http://trac.osgeo.org/osgeo4w/.

Adding GDAL command line tools to your path

Open System from Control Panel and select "Advanced System Settings". Click "Environment Variables" and select "Path" variable from the list (if you cannot edit, you do not have the rights).

Append ;C:\Program Files (x86)\GDAL to the value field (note the semicolon).

If you're using the OSGeo4W-installer, then you may have copy-paste semicolon followed by the path to GDAL and the path to "gdal19.dll" e.g.

;C:\Program Files\ms4w\tools\gdal-ogr\;C:\Program Files\ms4w\Apache\cgi-bin\

ogr2ogr

Note that the actual location of GDAL may vary depending on your system. To test that the tools are found from the path, type the command in terminal (Command Prompt in Windows):

ogr2ogr

To test that you also have a recent version of GDAL:

ogr2ogr --help

You should see the options -splitlistfields and -explodecollections in the printed help. If not, you need to update GDAL.

Packages

Start R and follow these steps to install the required packages:

install.packages(c("devtools", "sp", "rgdal", "raster"))
library(devtools)
install_github("rOpenGov/rwfs")

Note that rgdal version 0.9-1 or newer is needed. Then install the fmi package itself:

install_github("rOpenGov/fmi")

Contact

You are welcome to:

About

Finnish Meteorological Institute open data API R client

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • R 99.2%
  • Shell 0.8%