Comments (7)
glottolog = Glottolog()
languoids = {l.id: l for l in glottolog.languoids()}
l2geo = {}
for lid, l_ in languoids.items():
if l_.level == Level.language or l_.level == Level.dialect:
while l_.latitude is None and l_.lineage:
l_ = languoids[l_.lineage.pop()[1]]
if l_.latitude is not None:
l2geo[lid] = (l_.latitude, l_.longitude)
from clics2.
I think this mainly concerns dialects, and for these, we should default to using the coordinates of the corresponding Glottolog language.
from clics2.
Ah, is there a way to check for the corresponding language of a glottolog-dialect?
from clics2.
Just go up the glottolog tree until you find a language
? I think I have written that code before, but I cannot remember for what application and for with which API version of the glottolog data.
@xrotwang, is the reason you suggest that that most Glottolog dialects don't have coordinates?
Then it should be “walk up the glottolog tree until you find something with coordinates”, just in case future super-dialects contain coordinates?
from clics2.
Is there a distinction between "dialect" and "language"?
from clics2.
That may in fact increase the data, as we are loosing some 100 languages now...
from clics2.
Yes, in fact, we can save almost all languages in the sample. I only kicked out the Bookkeeping families.
from clics2.
Related Issues (20)
- standalone app without json HOT 8
- contribution and acknowledgements HOT 4
- use CLDF completely, without CLICS intermediate format
- transfer clics to another organisation? HOT 2
- Update datasets.txt
- [release of 1.0] Check for FALL maps to concepticon in all datasets HOT 14
- Remove obsolete output files HOT 1
- Add glottocode and bibkey to exported (downloadable data) HOT 6
- Pluggability
- must pin pylexibank dependency to 0.9
- Make sure all commands are idempotent HOT 1
- pin all dependencies? HOT 4
- factor out pyclics into its own repos HOT 4
- Should we aim for pylexibank 1.0 for this paper? HOT 2
- Check all datasets for compatibility with pylexibank 1.0 ... HOT 1
- Clics tries to write non-ASCII to a GML file HOT 3
- Reproducibility issues HOT 6
- More reproducibility issues HOT 16
- loading data: dataset.id needs to be specified HOT 7
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from clics2.