Azzera filtri
Azzera filtri

Python to MATLAB json.load

3 visualizzazioni (ultimi 30 giorni)
Ali
Ali il 15 Ago 2016
Hello buddies, I need to download automatically from this interface:
Here is the python script which probably does the job:
https://github.com/akrherz/iem/blob/master/scripts/asos/iem_scraper_example.py
I tried to translate it to MATLAB, but I cannot retrieve data from the URL, it just gives some info. Here the initial part of my code:
URL = 'http://mesonet.agron.iastate.edu/cgi-bin/request/asos.pydata=all&tz=Etc/UTC&format=comma&latlon=yes&year1=2012&month1=08&day1=01&year1=2012&month1=09&day1=01'; STATE = 'MN'; NETWROK = 'AWOS%s_ASOS%MN';
%get metadata---------------------------- uri = 'http://mesonet.agron.iastate.edu/geojson/network.php?network=%sAWOS.php';
%HEADER = http_createHeader('referer',uri) %DATA = urlread2(uri,'', '', HEADER) urlread(uri)
ans =
{"type":"FeatureCollection","crs":{"type":"EPSG","properties":{"code":4326,"coordinate_order":[1,0]}},"features":[]}
Any help is really appreciated. Thank you.

Risposte (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by