Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.


Table of contents:

Table of Contents
excludeTable of contents






About Import to Excel

DMI’s open data is retrieved in JSON format (”JavaScript Object Notation”).

You are able to import the JSON response of an API query directly into newer versions of Excel by following the guide below.


From Excel data can easily be saved in .csv format. 

If you want to convert JSON directly into a .csv file several "JSON to CSV converters" can be found online. 


How to query the DMI Open Data API directly from Excel

StepActionScreen dump
1Open Excel and click the Data tab

2Click New Query  From Other Sources > From Web

3

Enter your DMI open data query in the URL text field and press OK

(Remember to include your api-key in the query)

4Click Into Table (on the convert tab)

5

Right click the value of "features" (List)

Click Drill Down

6Click To Table

7Click OK

8Click the button with left and right arrows

9

Uncheck "use original column name as prefix"

Click OK


10Click the button with left and right arrows at the top of the "geometry" column.

Image Added

11

Click the button with left and right arrows at the top of the "coordinates" column.

Click Extract Values

(you can also choose "Expand to New Rows". This will give you two identical rows for each observation. One row for latitude coordinates and one for longitude).

1112

Select a delimiter from list for concatenating the coordinates

Press OK

(In this example we chose tabulator semicolon as the delimiter)

Image RemovedImage Added

1213

Click the button with left and right arrows at the top of the "properties" column

Press OK in the the window that appears

1314Click Close and Load to finalise the import process.