Wednesday, January 04, 2006

Paleomap Project & Geoprocessing Script

Been super-busy and so have not posted in quite some time. There are a number of things that have been occupying my time, but let's start with the Python script that I have been developing.

The Paleomap Project, developed by Dr. Chris Scotese, is designed to display the evolving Earth as tectonic plates have shifted through time. This project is recognized worldwide as a resource for students and teachers of Earth history. A nice overview can be found here. (Oh, and did you catch the reference to Chris and his work on Very Spatial Episode 21?)

Well, I have been helping him to integrate the Plate Tracker program that Chris wrote in VB6 into ArcMap. Put quite a bit of effort into this, but as always with such efforts, I sure learned a lot. The program allows users to view how different polygons on the Earth's surface would look in a given time period of Earth's history (measured in millions of years).

I will not post the code, but here is the logic of the script:
  • Convert polygon to table of XY coords

  • Launch Plate Tracker (VB6 executable) which shifts the coords according to the time period selected

  • Python once again takes over and converts the shifted coords into a new polygon feature class
I used VBA to direct the activities of the Python script and Plate Tracker. A single VBA button launches a form where users can select from any of the layers currently in the ArcMap project. The VBA then calls the Python script by creating a geoprocessing object within the VBA instead of the more traditional method of invoking a geoprocessing tool from a button on a toolbar with parameters. This is because the VBA code is then forced to wait for the geoprocessing object (in this case my script) to complete before finishing with the next command. The script then calls the Plate Tracker program, waits for this to finish, and then resumes to put the shifted pieces back together again.

Works like a charm. The two biggest hurdles that I had to overcome were (1) handling multipart and donut (inner circles) polygons, and (2) Ensuring that the resulting polygon contained the same attributes as the original file. Solving these hurdles taught me a lot about lists and sublists in Python. Special thanks to all the folks over at ArcView-L for helping me out with the donut polygon problems. This is a great listserv where folks will definitely get back to you.

2 comments:

xjd7410@gmail.com said...

true religion outlet
coach outlet
fitflops sale clearance
louis vuitton outlet stores
tory burch sale
michael kors outlet
vans shoes
louis vuitton outlet
beats wireless headphones
ray ban sunglasses
basketball shoes
gucci bags
michael kors handbags
coach outlet
christian louboutin outlet
louis vuitton handbags
nike air max
louis vuitton outlet
hollister clothing
cheap oakley sunglasses
kate spade handbags
coach outlet
coach outlet
christian louboutin outlet
gucci outlet
toms shoes
louis vuitton bags
cheap jerseys
true religion jeans
nike outlet
louis vuitton bags
lebron james shoes
fake watches
rolex submariner
oakley sunglasses
polo ralph lauren
christian louboutin shoes
coach factory outlet
christian louboutin sale
adidas yeezy
2016.7.27haungqin

xjd7410@gmail.com said...

true religion outlet
coach outlet
fitflops sale clearance
louis vuitton outlet stores
tory burch sale
michael kors outlet
vans shoes
louis vuitton outlet
beats wireless headphones
ray ban sunglasses
basketball shoes
gucci bags
michael kors handbags
coach outlet
christian louboutin outlet
louis vuitton handbags
nike air max
louis vuitton outlet
hollister clothing
cheap oakley sunglasses
kate spade handbags
coach outlet
coach outlet
christian louboutin outlet
gucci outlet
toms shoes
louis vuitton bags
cheap jerseys
true religion jeans
nike outlet
louis vuitton bags
lebron james shoes
fake watches
rolex submariner
oakley sunglasses
polo ralph lauren
christian louboutin shoes
coach factory outlet
christian louboutin sale
adidas yeezy
2016.7.27haungqin