SDMX in EViews Download timeseries Louis de Charsonville December - - PowerPoint PPT Presentation

sdmx in eviews
SMART_READER_LITE
LIVE PREVIEW

SDMX in EViews Download timeseries Louis de Charsonville December - - PowerPoint PPT Presentation

SDMX in EViews Download timeseries Louis de Charsonville December 3, 2016 1/18 Table of contents 1. SDMX 2. smdx.herokuapp.com 2/18 SDMX What is SDMX ? SDMX stands for S tatistical D ata and M etadata e X change. Goal:


slide-1
SLIDE 1

SDMX in EViews

Download timeseries

Louis de Charsonville December 3, 2016

1/18

slide-2
SLIDE 2

Table of contents

  • 1. SDMX
  • 2. smdx.herokuapp.com

2/18

slide-3
SLIDE 3

SDMX

slide-4
SLIDE 4

What is SDMX ?

  • SDMX stands for Statistical Data and Metadata eXchange.
  • Goal: Standardizing format to exchange timeseries.
  • Sponsored by international organisations: OECD, ECB, BiS, IMF,

etc.

  • Consists of technical standards and statistical guidelines.

3/18

slide-5
SLIDE 5

What is SDMX ?

  • SDMX stands for Statistical Data and Metadata eXchange.
  • Goal: Standardizing format to exchange timeseries.
  • Sponsored by international organisations: OECD, ECB, BiS, IMF,

etc.

  • Consists of technical standards and statistical guidelines.

In two words SDMX is a file format and a markup language. Example

3/18

slide-6
SLIDE 6

What type of content can I download with SDMX ?

What type of content can I download with SDMX ?

  • a timeseries
  • a dataset
  • information on datasets

4/18

slide-7
SLIDE 7

smdx.herokuapp.com

slide-8
SLIDE 8

Outline

Goal

  • EViews cannot read (yet) SDMX format.
  • but EViews can read HTML table on the web.

Example

%url = "http://www.bdm.insee.fr/bdm2/affichageSeries?idbank =001775994&codeGroupe=1794" import(t=html) %url

5/18

slide-9
SLIDE 9

How does sdmx.herokuapp.com work ?

sdmx.herokuapp.com translates SDMX flow into HTML tables

  • 1. Find the id of the resource you are looking for (dataset or

timeseries) for a provider (ECB, Eurostat, Insee).

  • 2. The url for the resource is :

http://sdmx.herokuapp.com/provider/resource/id resource

6/18

slide-10
SLIDE 10

Example 1 - Eonia

Data: Eonia rate on the ecb website.

  • provider: ecb
  • resource: series
  • id resource: EXR.A.E2.USD.EN00.A

The url is : http://sdmx.herokuapp.com/ecb/series/exr.a.e2.usd.en00.a EViews code:

% url = "http://sdmx.herokuapp.com/ecb/series/exr.a.e2.usd .en00.a" import(t=html) %url

7/18

slide-11
SLIDE 11

Example 2 - French Business climate

Data: French business climate on the Insee webiste.

  • provider: insee
  • resource: dataset
  • id resource: climat-affaires

The url is : http://sdmx.herokuapp.com/insee/dataset/climat-affaires EViews code:

% url = "http://sdmx.herokuapp.com/insee/dataset/CLIMAT- AFFAIRES" import(t=html) %url

8/18

slide-12
SLIDE 12

smdx.herokuapp.com

Filters

slide-13
SLIDE 13

Filters

The app allows to apply the standard SDMX filters, namely

  • 1. limit the number of observations retreived. For example, data only

since 2014, or the last 10 observations.

  • 2. cut a dataset along its dimensions: get quaterly data or only SA

data. A filter is used by adding ?name of filter=something at the end

  • f the url.

9/18

slide-14
SLIDE 14

Limit the number of observations

There are four filters to limit the number of observations retrieved:

  • startPeriod
  • endPeriod
  • firstNObservations
  • lastNObservations

Example Data since 2003 of annual average of EONIA rate:

/ecb/series/EXR.A.E2.USD.EN00.A?startPeriod=2003

10/18

slide-15
SLIDE 15

Cut a dataset (1/4)

“A dataset can be described as a container of ordered

  • bservations. Observations are classified by dimensions such as

country, age, sex, and time period. Observations may be clustered into series, in particular, time series”. Example - HICP dataset HICP dataset has three dimensions:

  • Frequency: either monthly or annual data.
  • Product: which kind of product: cars, bread, etc.
  • Nature: weight or index.

11/18

slide-16
SLIDE 16

Cut a dataset (2/4)

Only subgroups can be retrieve by restricting dimensions (only monthly data for instance). It can be done by adding a filter at the end of the url. ?name of dimension=id of dimension Example - Monthly data for HICP dataset

  • the name of the dimension is freq.
  • the id of monthly dimension is M.

− → http://sdmx.herokuapp.com/insee/dataset/ipch-2015-fr-coicop?freq=M

Test

12/18

slide-17
SLIDE 17

Cut a dataset (3/4)

Multiple filters can be used and are separated by an &. Example - Annual weights for HICP dataset

  • dimensions are freq and nature
  • id of dimensions are A and POND

− → http://sdmx.herokuapp.com/...?freq=A&nature=POND

Test

13/18

slide-18
SLIDE 18

Cut a dataset (4/4)

Be careful!

  • Case do matter. Example
  • Some combinations might don’t exist. For instance, monthly weights

for HICP.

  • Since output is a table, you have to use a filter when a dataset has

several time frequencies.

  • When a dataset is too big, it cannot be downloaded in a single
  • request. Multiple request should be done along its several

dimensions.

14/18

slide-19
SLIDE 19

Use filters

To retrieve datasets, you need their ids and their dimensions.

  • The list of datasets for a provider can be found at:

.../provider/dataflow

  • the list of the timeseries and filters for a dataset can be found at :

.../provider/dataflow/dataset Example

  • List of ECB datasets: .../ecb/dataflow
  • List of series in EONIA dataset : .../ecb/dataflow/EON

15/18

slide-20
SLIDE 20

smdx.herokuapp.com

Other functionnalities

slide-21
SLIDE 21

Other providers

You can download data from 3 others providers:

  • Quandl
  • FRED
  • Bureau of Labor Statistics

Note

  • These providers require an API key (free).
  • You can only retrieve individual series.

To use it: http://sdmx.herokuapp.com/provider/api key/id resource

16/18

slide-22
SLIDE 22

Example

Example - The US unemployment rate of FRED Id of the timeseries is unrate. The url is http://sdmx.herokuapp.com/fred/api key/unrate.

17/18

slide-23
SLIDE 23

Other SDMX providers

You can also retrieve data from other SDMX providers like widuking, the OECD, the BIS, using the app as long as you know the url to the sdmx resource. To use it: http:sdmx.herokuapp.com/req?url=’url to sdmx’ Example - Data from the BIS on widukind.

  • The url of the resource on the widukind website is:

http://widukind-api.cepremap.org/api /v1/sdmx/BIS/data/DSRP/Q.BE.N

  • To download it:

http://sdmx.herokuapp.com/req?url=’http:// widukind-api.cepremap.org/api/v1/sdmx/BIS/ data/DSRP/Q.BE.N’ Test

18/18

slide-24
SLIDE 24

EViews subroutine

To ease the use of the app, I’ve coded a subroutine that you can download here.

19/18

slide-25
SLIDE 25

Questions ?

smdx.herokuapp.com – Other functionnalities 19/18