MATLAB Answers

Downlaoding data from a webpage

11 views (last 30 days)
Abhinav on 27 Jan 2018
Commented: Abhinav on 28 Jan 2018
I want to save the data shown on USGS webpage: USGS data using Matlab. I am using MatLab 2014a; therefore, I have to use 'urlwrite' function. When I use it, I get the HTML content, not the data in txt format. Any suggestions on how do I download the data that is available on the link? I used the following code:
outfilename = urlwrite(url,filename);
Abhinav on 27 Jan 2018
Okay, I will try to work it out using your suggestion. Thanks!

Sign in to comment.

Accepted Answer

Walter Roberson
Walter Roberson on 28 Jan 2018
Remove the trailing '/' in your URL.

More Answers (0)


Community Treasure Hunt

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

Start Hunting!