File Exchange Pick of the Week

Our best user submissions

ip to location

In the last few weeks I have been adding a some location information to this blog, from the map to the right that shows where all the weekly visits to this blog are coming from, to the map that was picked two weeks ago that shows where File Exchange authors are located in the world. Continuing with that location theme is a quick little tool that will tell you what country a given IP address is registered to. For instance, I am writing this post from


>> ip2loc('12.173.202.2')
ans =
UNITED STATES

This IP happens to be a hotel I am staying at tonight before I give a talk about MATLAB Friday afternoon.

I liked that this was a simple implementation, and that data from an outside source was able to be brought easily into MATLAB and used here. When I first found the application, I thought it would be nice to have a command line version. Divakar was kind enough to modify his code and post it here.

|
  • print

댓글

댓글을 남기려면 링크 를 클릭하여 MathWorks 계정에 로그인하거나 계정을 새로 만드십시오.