Giter Club home page Giter Club logo

luftkvalitet's Introduction

Luftkvalitet

Go package to get air quality data from api.nilu.no. It supports retrieval of: up to date data (latest measurements); historical data; available areas, components, stations and aqis; and air quality forecasts.

Example

For more examples have a look at gonum-plot-example, polluteman or in example/.

Get current air quality measurements from Tromsø:

package main

import (
	"fmt"

	"github.com/fjukstad/luftkvalitet"
)

func main() {

	areas := []string{"Tromsø"}

	m, err := luftkvalitet.GetMeasurements(luftkvalitet.Filter{Areas: areas})
	if err != nil {
		fmt.Println(err)
		return
	}

	fmt.Println(m)
}

produces (on 4.12.2016 19:44 EST):

[{{{Troms og Finnmark Tromsø Tromsø} {69.67957 18.95402} Tverrforbindelsen} NO0085A PM10 2016-12-05 00:00:00 +0100 +0100 2016-12-05 01:00:00 +0100 +0100 10.34 µg/m³ 1 6ee86e} {{{Troms og Finnmark Tromsø Tromsø} {69.65625 18.96372} Hansjordnesbukta} NO0079A PM10 2016-12-05 00:00:00 +0100 +0100 2016-12-05 01:00:00 +0100 +0100 11.44 µg/m³ 1 6ee86e} {{{Troms og Finnmark Tromsø Tromsø} {69.65625 18.96372} Hansjordnesbukta} NO0079A PM2.5 2016-12-05 00:00:00 +0100 +0100 2016-12-05 01:00:00 +0100 +0100 5.1 µg/m³ 1 6ee86e} {{{Troms og Finnmark Tromsø Tromsø} {69.65625 18.96372} Hansjordnesbukta} NO0079A NO2 2016-12-05 00:00:00 +0100 +0100 2016-12-05 01:00:00 +0100 +0100 -0.0864654577 µg/m³ 1 6ee86e}]

you get the idea?

Acknowledgements

The data belongs to The Norwegian Institute for Air Research (NILU), see luftkvalitet.info and nilu.no for more information.

luftkvalitet's People

Contributors

fjukstad avatar

Watchers

 avatar  avatar

Forkers

congca

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.