spacer1
spacer2 1_1 1_2
2_1
 Subscribe
 The MP2K Update!
 
 
 
 Magazine
Front Cover
What's New
Articles
News
Sample Data
Gallery
Advertise
About
 Features
MapPoint 2013
Press Releases
MapPoint Forums
Companies
Link to MP2Kmag
Wish List
MapPoint Trial
Authors
 Earlier Content
Past News Items
Past What's New Announcements
 Sponsors
 Order

MapPoint 2013

Programming MapPoint in .NET

MapPoint Book

  Spatial Community
SVG Tutorials
MapPoint

Map Visitors

  MAPPOINT Q & A  

Top | Post New Question | Read All | MP2K Asks Microsoft

625 Naomi - March 11, 2002

I have a dataset of 390 hospitals with zipcodes, divided into high and low volume categories. I would like to be able to calculate the average distance from any given low-volume hospital to the closer high-volume hospital. I tried to look at Gilles Kohl message cited in the answer to another question here with a similar problem, but was not able to find it in the newgroup. Thanks!

Answer:

This is a fairly brute force problem. First I assume you have MapPoint datasets with this data, right? Also, what distance do you want, crow flight or driving? Basically you would have to do code with an outer loop to access each low-volume hospital, and inner loop to process each high-volume hospital. Then calculate the distance you want between each outer-inner loop pair. Either use the Distance method to get the crow flight distance, or create a route with each set of inner-outer loop points as waypoints to get the driving distance. Save the results to a database. Then you can run a query to find the minimum distance for each low-volume hospital. Not too hard, but a fair number of steps involved.

- Walt Cygan

Post New Answer / Follow-up


Google
 
MP2Kmag Internet


 Recent Discussion
 Resources


Want Your Site To Appear Here?

   © 1999-2012 MP2K. Questions and comments to: website@mp2kmag.com
  Microsoft and MapPoint 2002/2004/2006/2009/2010/2011/2013 are either trademarks or registered trademarks of Microsoft.