Wednesday, March 5, 2014

Phimon Rat town created

Yesterday, the upgrade of the TAO Phimon Rat (องค์การบริหารส่วนตำบลพิมลราช) to a town municipality (เทศบาลเมืองพิมลราช) was announced in the Royal Gazette. As the upgrade was effective February 22, this announcement came rather fast compared to other municipal upgrades - many of them still not published though many years effective already. Today, the constituencies were announced as well, so the election for the municipal council and the mayor won't take long.

What is the most interesting part of this new municipality is however its boundary, as one can see on the last page of announcement. The municipality was originally a TAO which covered the area of the Tambon not covered by any other municipalities, and in this case the Tambon Phimon Rat was already covered by parts of the town Bang Bua Thong. And not just parts of the Tambon were cut away, in fact the remaining area consists of two chunks without any connection, approximately one third east of bang Bua Thong and two third west of it.
Also interesting is the population development of the Tambon and the TAO, I have taken the registration data from DOPA into a little sheet to visualize how much the population did grow from 1993 (6946 in whole Tambon) to 2012 (39620 in TAO). Quite a clear indication of how much the suburbs of Bangkok grow.

Thursday, February 27, 2014

New Muban in Galyani Vadhana district, Chiang Mai

Today the Royal Gazette published the announcement of the creation of a new administrative village in Mae Daet subdistrict, Galyani Vadhana district, Chiang Mai, increasing the number of Muban in the subdistrict to eight and for the whole district to 22. The announcement became effective on January 14, and was signed on the same day by the deputy governor (ปลัดจังหวัด) Chokdi Omrawat (โชคดี อมรวัฒน์) as the acting province governor. It was previously approved by the Ministry of Interior in its ministerial order ๐๓๑๐.๑/๑๕๔๔๐ dated December 24.

The new villages has been split off from village number 7 named Ban Tala Mong (บ้านแม่ตะละม้ง), and received the name Ban Tala Mang Mai (บ้านแม่ตะละม้งใหม่) - meaning simply "new Tala Hmong village". From the description of the boundaries listed in the announcement, the division between the two administrative villages goes right through the actual main settlement itself, with the new village covering the southern part of the settlement and what is left of village 7 the northern parts. Since the village is located within forests, most parts of the two administrative villages are uninhabited land.

Friday, February 21, 2014

ISO 3166-2 code for Bueng Kan

When the province of Bueng Kan was created in 2011, it quite quickly got the code 38 assigned by the Department of Provincial Administration - which was the obvious choice anyway as there was no other free number in the number range for the northeastern provinces. While there was no official new version of the TIS1099 national standard - the latest is still from 2005 - this list maintained by DOPA is in fact the current working copy of the national standard. The ISO 3166-2 standard, giving codes for the first-level subdivisions of all countries, uses the same codes prefixed with a TH-, but none of the updates since 2011 covered Thailand so far.

Today, ISO announced that they have changed the system of updating these codes named "Online Browsing Platform", instead of the newsletters it now has live updates on their website, to which one can subscribe - for free but one has to register. But actually thanks to the update scanner plugin in Firefox I will get notified whenever the page on Thailand will be updated, without having to register with ISO.

Anyhow, though none of the newsletters announced the code for Bueng Kan yet, with the change to the new platform the code for Bueng Kan is now also included, and without any surprise it is TH-38.

Thursday, January 30, 2014

Old municipal upgrades announced

On Monday, a set of 25 announcements were published in the Royal Gazette, 24 of them giving the official confirmation of the upgrade of subdistrict administrative organizations to subdistrict municipalities, and one [Gazette] was about the upgrade of Ko Samui municipality to the highest municipal state (Thesaban Nakhon, เทศบาลนคร). The interesting part - all of these upgrades already happened in 2011 and 2012, so it took one to two years to make them into announcements in the Royal Gazette. The announcements itself were all signed before the date they became effective, so the first page of each of the PDF files cannot be the reason why the publication took so long. But since they all include the description of the municipal borders as well as a map, it must the preparation of this appendix which delayed the announcement - and which made several 100 further still announcements still pending to be published. In case you want to have details on all those announcements, best look at the XML file - I guess listing them all here would be too much detail.

As an example I have added the map from the upgrade of Ban Krang TAO (เทศบาลตำบลบ้านกร่าง), Si Prachan district in Suphanburi, because in this case the boundaries are more interesting than for most of the other ones which covers a complete Tambon. The subdistrict municipality Si Prachan (เทศบาลตำบลศรีประจันต์) covers the small town around the district office, and though the district office is located on the other side of the Tha Chin river in Si Prachan subdistrict, most of the municipality is located within Ban Krang subdistrict. Thus Ban Krang municipality only covers the remaining parts of the subdistrict, and to make it even more confusing, the municipality has two parts not connected with each other. In some cases, the boundaries between TAO and municipality were changed to avoid splitting the area in two disconnected parts, but I have no idea if the small part south of Si Prachan municipality will be transferred to it someday. The main information I can find with these maps is the location of the municipal office, and since this area already had been visited by the Streetview car I can embed the view of the office building below. As the car passed there in August 2012, the same month the upgrade became effective, the big sign still shows Ban Krang TAO - by now it must have been updated. By the way: Wikidata has an item on Ban Krang municipality already, and I have filled it with a lot of statements already.
View Larger Map

Wednesday, January 22, 2014

TambonBot on Wikidata

It took quite some time, but some days ago my automatic Wikidata editing bot has been approved, and it already did 12,000 edits on the 2428 administrative entities which have a corresponding Wikidata item. So far I have done only the trivial things which don't necessarily includes the addition of sub-statement to statements or sources. The activities done so far were
  • Normalize the item names not to include the type, e.g. Bueng Kan Province became Bueng Kan, both for English and for German.
  • For Thai however, the name always includes the type, thus Bueng Kan Province is labeled จังหวัดบึงกาฬ.
  • Give a description with the full hierarchy to be avoid any potential ambiguities, e.g. "district in Bueng Kan province, Thailand". For German I haven't implemented it yet as the Grammar makes it a little bit more complicate, for English and Thai it was simple string concatenation.
  • Every item now has the link to the country Thailand
  • Every item now is linked to the one in which it is located, except for the TAO and Thesaban - I am not sure if I should link the province, the district or every (partially) covered Tambon.
  • The type of the entity is also linked, for some reasons twice, once as "instance of" and once as "type of administrative unit".
  • Those entities which have a corresponding boundary item on OpenStreetMap are now linked as well.
As both the parent unit as well as the type could have changed in past, adding the historical values with the corresponding start and end dates is still an open task to be programmed.

A property to hold the geocode of the entity has been created by now as well - when I saw that it received the property id 1067 I realized I should have waited a bit longer to catch the number 1099 - as this code is related with the TIS 1099 standard. The code to add these identifiers is nearly finished, still need some polishing to add the references to the corresponding source of the code - TIS 1099:2535, TIS 1099:2548 or the full code list from DOPA. While waiting for this property to be created, I finally wrote down an article on Wikipedia about this Thai standard - copyreading or translation is welcome...

Also almost completed is the code to fill the list of subdivisions, in this case clearly leaving out the TAO and municipalities, as these are no real subordinate of any of the central administrative units. There are several other edits which are easiest done by a bot, I am collecting my ideas on the bot userpage. The item on Bueng Kan is kind of my test item, having the biggest number of statements of all the Thai subdivisions now, and already takes quite long to load in a Webbrowser.

I still learn more about what Wikidata can do - like discovering more properties which can be applied to the administrative unit I work with, as well as discovering of what it will be able to do in future once developing progresses - e.g. the data value for the population number is not yet available. But I also had my first negative experience there: As Phuket is the province with the smallest number of subdivisions, I added all those items which have no Wikipedia article yet as more-or-less blank items to be filled by my bot later (except the PAO, those are a really special thing). As the idea behind Wikidata is to be more than just a repository of data for Wikipedia articles, these items were perfectly fine to be added. But since there was no Wikipedia link as well as no link from any other item, one admin thought them to be unused orphans and deleted them, without notifying me or asking whether these were correct or not. So I had to do the same work twice, the only positive thing was that now all of these items contain the list of neighboring items, to make sure none looks like an unused orphan anymore.

Friday, December 27, 2013

Municipal area transfer in Rayong

On Monday, the change of the boundaries of two adjoining municipalities in Rayong province was announced in the Royal Gazette. Choeng Noen (เทศบาลตำบลเชิงเนิน), located north and east of Rayong city [Gazette] and Noen Phra (เทศบาลตำบลเนินพระ), located west of Rayong city [Gazette] are connected by a narrow area running parallel north of Sukhumvit road. I wasn't able to find a map of the original municipality boundaries, but it is possible to get them by the Tambon. Both municipalities were originally TAOs covering the same-named Tambon, except those area which are covered by Rayong city, and in 1998 the boundaries of the Tambon in Mueang Rayong district were officially defined [Gazette]. Though the boundaries are only defined in written text and not as a map, by comparing the coordinates it seems that in fact the two Tambon have no adjoining area, being separated by the city of Rayong. Thus the with the announcements now, Choeng Noen gained some area west of Rayong city, with a very narrow connection of the newly gained area north of Rayong city.

The interesting question is whether this change for the municipal boundaries will also cause an adjustment of the subdistrict boundaries, to keep the two municipalities within their original Tambon.

I have tried to turn the main part of the two maps within the announcements into a single Google map, the pink boundary is the area which I believe was added to Choen Noen.

View Choeng Noen, Noen Phra in a larger map

Friday, December 20, 2013

Busy times

To my shame I have neglected the blog in the last month, mostly because I was very busy with working through issues which not directly could be made into a blog post.

One big task has reached another milestone - I finally finished to add the election dates in 2004 which I could deduce from a PDF by the Election Commission listing the term ends of 2008. I now have little over 19,000 council elections in the XML, and a somewhat smaller number of mayor elections since I only added them if I have the name of the mayor, or the term differs from the council term. But sadly the elections aren't done completely yet, this year had another 3,500 local elections. Though there is no concise collective result, at least a good part could be found on the various pages of the province branches of the Election Commission. I am still working on adding those, so more on that in a separate blog posting.

The other task started with my "discovery" of Wikidata. I have now worked through all the Wikipedia articles on the administrative subdivisions and added the ID at Wikidata to all the corresponding entries in my XML. This included several merges of Wikidata entries, where two language editions of Wikipedia had an article but those were not joined yet. Also, some had to be split, the good old confusion between district or subdistrict and the local governments (cities, towns). Now there are 2362 Wikidata items, almost all correspond to at least one Wikipedia article. The next steps are now the programming of a bot to fill these items with statements - I have started and succeeded with a few test edits, but the library to access Wikidata with C# needs a lot of rework before it becomes really usable - so another work to do. At least I have to do some programming, not just XML editing... I detailed analysis of the Wikipedia article I found during this inventory will be posted later, and of course will keep you updated once the TambonBot starts operating.
I wish all my readers a happy Christmas and a good new year, hope I can return to the more regular posting after the holidays.