Hello Yoshiro,

> From this, I would like to generate such a matrix
> as shows which polygones are adjacent to each other,
> and which are not.

No way of doing this with MapInfo Pro alone I believe. Perhaps someone on the list has 
developed 
a batch adjacent test utility?

It is possible, and quite straight forward, in MapBasic. You can make an adjacent test 
on any 
region using a SELECT statement. For example;

Assuming I have an object variable called "FranceObj" which contains a MI region of 
France.

select * from WORLD where obj intersects FranceObj into FranceNeighbours

There is a catch. This select will also pick-up France itself. This can be ignored 
while running 
through the "FranceNeighbours" results or filter with an extra clause on the "where". 
e.g.

Assuming FranceID is an integer containing the rowid of the France record in table 
WORLD.

select * from WORLD where obj intersects FranceObj and rowid <> FranceID into 
FranceNeighbours

Note that these methods do rely on the query data having good integrity. ie. adjacent 
countries/regions do meet seamlessly.

There are lots of ways a MapBasic program could be structured. Perhaps the simplest is 
to have 
a loop running through the table of you Australian territories. Inside that loop, make 
an adjacent test 
such as above, and then process the results into an array of type logical. 
Unfortunately MB only 
supports 1D arrays, so you may need to process and output one row of your matrix at a 
time.

Regards,
Warren Vick
Europa Technologies Ltd, U.K.
www.europa-tech.com
----------------------------------------------------------------------
To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put
"unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]

Reply via email to