Skip to content

Commit

Permalink
more fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
xrotwang committed Oct 9, 2024
1 parent fef1cad commit cfbe197
Show file tree
Hide file tree
Showing 27 changed files with 24,981 additions and 20,024 deletions.
2 changes: 1 addition & 1 deletion .zenodo.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"title": "CLDF dataset with data and supplements for Barlow 'Loss of colexification of \u2018hand\u2019 and \u2018five\u2019 in Austronesian languages'",
"title": "CLDF dataset with data and supplements for Barlow \u201cLoss of colexification of \u2018hand\u2019 and \u2018five\u2019 in Austronesian languages\u201d",
"access_right": "open",
"keywords": [
"cldf:StructureDataset",
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -88,4 +88,4 @@ Kela (Papua New Guinea),possibly shared change between Bugawac/Kela

The following CLDF datasets are available in [cldf](cldf):

- CLDF [StructureDataset](https://github.com/cldf/cldf/tree/master/modules/StructureDataset) at [cldf/StructureDataset-metadata.json](cldf/StructureDataset-metadata.json)
- CLDF [StructureDataset](https://github.com/cldf/cldf/tree/master/modules/StructureDataset) at [cldf/StructureDataset-metadata.json](cldf/StructureDataset-metadata.json)
6 changes: 3 additions & 3 deletions barlowhandandfivecommands/maps.py
Original file line number Diff line number Diff line change
Expand Up @@ -120,8 +120,8 @@ def run(args):

readme.append('\n  | Value | Count | Description')
readme.append('---:| --- | ---:| ---')
readme.append('⏺| Melanesian | {} | '.format(sum(1 for l in cldf['LanguageTable'] if l['Melanesian'] == 'yes')))
readme.append('▼| Non-melanesian | {} | '.format(sum(1 for l in cldf['LanguageTable'] if l['Melanesian'] == 'no')))
readme.append('⏺| in Melanesia | {} | '.format(sum(1 for l in cldf['LanguageTable'] if l['Melanesia'] == 'yes')))
readme.append('▼| not in Melanesia | {} | '.format(sum(1 for l in cldf['LanguageTable'] if l['Melanesia'] == 'no')))

readme.append('\n![num_syst](num_syst.svg)\n')

Expand All @@ -130,7 +130,7 @@ def run(args):
'cldfbench',
'cldfviz.map',
'--parameter', 'num_syst',
'--language-properties', 'Melanesian',
'--language-properties', 'Melanesia',
'--colormaps',
json.dumps({c['ID']: c['color'] for c in parameters['num_syst']}),
'--language-properties-colormaps', '{"yes":"circle","no":"triangle_up"}',
Expand Down
4 changes: 2 additions & 2 deletions cldf/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ property | value
[dc:conformsTo](http://purl.org/dc/terms/conformsTo) | [CLDF StructureDataset](http://cldf.clld.org/v1.0/terms.rdf#StructureDataset)
[dc:license](http://purl.org/dc/terms/license) | https://creativecommons.org/licenses/by/4.0/
[dcat:accessURL](http://www.w3.org/ns/dcat#accessURL) | https://github.com/cldf-datasets/barlowhandandfive
[prov:wasDerivedFrom](http://www.w3.org/ns/prov#wasDerivedFrom) | <ol><li><a href="https://github.com/cldf-datasets/barlowhandandfive/tree/6a976e5">cldf-datasets/barlowhandandfive 6a976e5</a></li><li><a href="https://github.com/glottolog/glottolog/tree/v5.0">Glottolog v5.0</a></li></ol>
[prov:wasDerivedFrom](http://www.w3.org/ns/prov#wasDerivedFrom) | <ol><li><a href="https://github.com/cldf-datasets/barlowhandandfive/tree/fef1cad">cldf-datasets/barlowhandandfive v1.0-21-gfef1cad</a></li><li><a href="https://github.com/glottolog/glottolog/tree/v5.0">Glottolog v5.0</a></li></ol>
[prov:wasGeneratedBy](http://www.w3.org/ns/prov#wasGeneratedBy) | <ol><li><strong>python</strong>: 3.10.12</li><li><strong>python-packages</strong>: <a href="./requirements.txt">requirements.txt</a></li></ol>
[rdf:ID](http://www.w3.org/1999/02/22-rdf-syntax-ns#ID) | barlowhandandfive
[rdf:type](http://www.w3.org/1999/02/22-rdf-syntax-ns#type) | http://www.w3.org/ns/dcat#Distribution
Expand Down Expand Up @@ -78,7 +78,7 @@ Name/Property | Datatype | Description
[Glottocode](http://cldf.clld.org/v1.0/terms.rdf#glottocode) | `string`<br>Regex: `[a-z0-9]{4}[1-9][0-9]{3}` |
[ISO639P3code](http://cldf.clld.org/v1.0/terms.rdf#iso639P3code) | `string`<br>Regex: `[a-z]{3}` |
`Number` | `integer` |
`Melanesia` | `string`<br>Valid choices:<br> `yes` `no` | Languages are classified as being in Melanesia if they are primarily spoken in PG, SB, VU, NC, or the Western New Guinea provinces of ID.
`Melanesia` | `string`<br>Valid choices:<br> `yes` `no` | Languages are classified as being in Melanesia if they are primarily spoken in PG, SB, VU, NC or the Western New Guinea provinces of ID.

## <a name="table-contributionscsv"></a>Table [contributions.csv](./contributions.csv)

Expand Down
2 changes: 1 addition & 1 deletion cldf/StructureDataset-metadata.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
{
"rdf:about": "https://github.com/cldf-datasets/barlowhandandfive",
"rdf:type": "prov:Entity",
"dc:created": "v1.0-15-g3c90f45",
"dc:created": "v1.0-21-gfef1cad",
"dc:title": "Repository"
},
{
Expand Down
14 changes: 7 additions & 7 deletions cldf/codes.csv
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,10 @@ five_replacement-count,five_replacement,‘count’,The word for ‘five’ deri
five_replacement-additionwith4,five_replacement,addition with 4,The word for ‘five’ derives from a formulation like ‘4+1’.,orange
five_replacement-part,five_replacement,‘part’,The word for ‘five’ derives from ‘part’.,blue
five_replacement-unclear,five_replacement,unclear,"The word for ‘five’ derives from a form other than *lima, but its etymology is unclear.",gray
num_syst-decimalproper,num_syst,decimal proper,A proper decimal system.,red
num_syst-decimalmodified,num_syst,decimal modified,A modified decimal system.,orange
num_syst-quinary,num_syst,quinary,A quinary system.,yellow
num_syst-binaryproper,num_syst,binary proper,A proper binary system.,blue
num_syst-binary3,num_syst,binary+3,A binary+3 system.,purple
num_syst-quaternary,num_syst,quaternary,A quaternary system.,black
num_syst-unknown,num_syst,unknown,Unknown system.,gray
num_syst-decimalproper,num_syst,decimal proper,A decimal system with atomic numerals ‘one’ through ‘nine’.,red
num_syst-decimalmodified,num_syst,decimal modified,A decimal system with one or more derived numerals lower than ‘ten’.,orange
num_syst-quinary,num_syst,quinary,A system that constructs numerals based on the number 5.,yellow
num_syst-binaryproper,num_syst,binary proper,A system that constructs the numerals ‘three’ and ‘four’ based on the number 2.,blue
num_syst-binary3,num_syst,binary+3,A system that constructs the numeral ‘four’ based on the number 2 but has an atomic ‘three’.,purple
num_syst-quaternary,num_syst,quaternary,A system that constructs numerals based on the number 4.,black
num_syst-unknown,num_syst,unknown,An unknown numeral system.,gray
2 changes: 1 addition & 1 deletion cldf/parameters.csv
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ ID,Name,Description,ColumnSpec
five,What is the word for ‘five’?,,
hand,What is the word for ‘hand’?,,
colex,Is there colexification?,,
dist,Is distinctness due to lexical replacement or phonological change?,"For those languages that lack colexification (i.e., languages with value “lexically distinct” for parameter “Is there colexification?”), the values for this parameter are “lexical replacement” or “phonological change”. However, some languages exhibit both lexical replacement and (partial) colexification; this is possible when there has been replacement of both ‘hand’ and ‘five’ such that the new forms are (partially) colexified: these cases are indicated by rows in the ValueTable with an empty value and a comment “(recolexification)”.",
dist,Is distinctness due to lexical replacement or phonological change?,"For those languages that lack colexification (i.e., languages with value “lexically distinct” for the parameter “Is there colexification?”), the values for this parameter are “lexical replacement” or “phonological change”. However, some languages exhibit both lexical replacement and (partial) colexification; this is possible when there has been replacement of both ‘hand’ and ‘five’ such that the new forms are (partially) colexified: these cases are indicated by rows in the ValueTable with an empty value and a comment “(recolexification)”.",
repl_hand,Was there lexical replacement of ‘hand’?,,
repl_five,Was there lexical replacement of ‘five’?,,
hand_replacement,What replaced ‘hand’?,"Values for this parameter are descriptions of the most likely etymology (traced as far back as possible in the Austronesian family) given for the word in the language that came to mean ‘hand’; values followed by “?” are somewhat uncertain; and those followed by “??” are even more uncertain; when no likely etymology has been posited, then the value is given simply as “unclear” (with no preceding etymology). Values are batched into five different categories, referenced by the `Code_ID` column.",
Expand Down
2 changes: 1 addition & 1 deletion cldf/requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ certifi==2022.12.7
cffi==1.16.0
chardet==5.2.0
cldfbench==1.14.0
-e git+https://github.com/cldf-datasets/barlowhandandfive@3c90f456f68853d32e3ac5c2e66c969a91514255#egg=cldfbench_barlowhandandfive
-e git+https://github.com/cldf-datasets/barlowhandandfive@fef1cad6373fa17637f327207cea238960178542#egg=cldfbench_barlowhandandfive
-e git+https://github.com/cldf-datasets/doreco/@8124db8c45f1186e998d7536401dc6d6dceebb32#egg=cldfbench_doreco
-e git+https://github.com/cldf-datasets/haigandschnellmulticast.git@a03269497020aeab5c862a0e8d294786d567c241#egg=cldfbench_haigandschnellmulticast
-e git+https://github.com/cldf-datasets/imtvault@1087aa3d1dc1d846bf2fdc986290d7950025c03b#egg=cldfbench_imtvault
Expand Down
20 changes: 12 additions & 8 deletions cldfbench_barlowhandandfive.py
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@
'dist',
'Is distinctness due to lexical replacement or phonological change?',
"For those languages that lack colexification (i.e., languages with value “lexically "
"distinct” for parameter “Is there colexification?”), the values for this parameter are "
"distinct” for the parameter “Is there colexification?”), the values for this parameter are "
"“lexical replacement” or “phonological change”. However, some languages exhibit both "
"lexical replacement and (partial) colexification; this is possible when there has been "
"replacement of both ‘hand’ and ‘five’ such that the new forms are (partially) colexified: "
Expand Down Expand Up @@ -224,13 +224,13 @@
'(3) dalk1234 is added (with numeral system “unknown”); (4) mori1267 is added '
'(split from maor1246: both with numeral system “decimal proper”); and '
'(5) ngga1239 is added (with numeral system “unknown”).'): {
'decimal proper': ('red', 'A proper decimal system.'), # (632x)
'decimal modified': ('orange', 'A modified decimal system.'), # (228x)
'quinary': ('yellow', 'A quinary system.'), # (290x)
'binary proper': ('blue', 'A proper binary system.'), # (22x)
'binary+3': ('purple', 'A binary+3 system.'), # (14x)
'quaternary': ('black', 'A quaternary system.'), # (5x)
'unknown': ('gray', 'Unknown system.'), # (83x)
'decimal proper': ('red', 'A decimal system with atomic numerals ‘one’ through ‘nine’.'), # (632x)
'decimal modified': ('orange', 'A decimal system with one or more derived numerals lower than ‘ten’.'), # (228x)
'quinary': ('yellow', 'A system that constructs numerals based on the number 5.'), # (290x)
'binary proper': ('blue', 'A system that constructs the numerals ‘three’ and ‘four’ based on the number 2.'), # (22x)
'binary+3': ('purple', 'A system that constructs the numeral ‘four’ based on the number 2 but has an atomic ‘three’.'), # (14x)
'quaternary': ('black', 'A system that constructs numerals based on the number 4.'), # (5x)
'unknown': ('gray', 'An unknown numeral system.'), # (83x)
}
}

Expand Down Expand Up @@ -517,6 +517,10 @@ def cmd_makecldf(self, args):

for concept in ['five', 'hand']:
for row in self.iterrows('Replacements_of_{}_in_Austronesian'.format(concept)):
row['Subgroup'] = {
'East Choiseul3': 'East Choiseul',
'Mainland New Caledonia': 'Mainland New Caledonian',
}.get(row['Subgroup'], row['Subgroup'])
gl = gl_langs[row['Subgroup']]
args.writer.objects['replacements.csv'].append(dict(
ID='{}-{}'.format(concept, row['Higher_count']),
Expand Down
10 changes: 5 additions & 5 deletions maps/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ View [interactive map](https://cldf-datasets.github.io/barlowhandandfive/maps/co

## Is distinctness due to lexical replacement or phonological change?

For those languages that lack colexification (i.e., languages with value “lexically distinct” for the parameter “Is there colexification?”), values for this parameter are “lexical replacement” or “phonological change”. However, some languages exhibit both lexical replacement and (partial) colexification; this is possible when there has been replacement of both ‘hand’ and ‘five’ such that the new forms are (partially) colexified: these cases are indicated by rows in the ValueTable with an empty value and a comment “(recolexification)”.
For those languages that lack colexification (i.e., languages with value “lexically distinct” for the parameter “Is there colexification?”), the values for this parameter are “lexical replacement” or “phonological change”. However, some languages exhibit both lexical replacement and (partial) colexification; this is possible when there has been replacement of both ‘hand’ and ‘five’ such that the new forms are (partially) colexified: these cases are indicated by rows in the ValueTable with an empty value and a comment “(recolexification)”.

&nbsp; | Value | Count | Description
--- | --- | ---:| ---
Expand All @@ -40,7 +40,7 @@ View [interactive map](https://cldf-datasets.github.io/barlowhandandfive/maps/di
&nbsp; | Value | Count | Description
--- | --- | ---:| ---
$${\color{white}⏺}$$ | no | 428 | The word for the concept ‘hand’ has not been replaced.
$${\color{red}⏺}$$ | yes | 390 | The word for the concept ‘hand’ has been replaced.
$${\color{red}⏺}$$ | yes | 390 | The word for the concept ‘hand’ has been replaced.
$${\color{gray}⏺}$$ | unknown | 456 | It is unknown whether or not the word for the concept ‘hand’ has been replaced.
&nbsp; | &nbsp; | **1274** | &nbsp;

Expand Down Expand Up @@ -101,23 +101,23 @@ View [interactive map](https://cldf-datasets.github.io/barlowhandandfive/maps/fi

## What is the numeral system?

The values for this parameter are taken from Barlow (2023), “Papuan-Austronesian contact and the spread of numeral systems in Melanesia”.
The values for this parameter are taken from Barlow (2023) “Papuan-Austronesian contact and the spread of numeral systems in Melanesia”, updated here to reflect changes between Glottolog 4.6 and Glottolog 5.0: (1) badu1237 is removed (subsumed within sund1252); (2) bali1287 is added (with numeral system “unknown”); (3) dalk1234 is added (with numeral system “unknown”); (4) mori1267 is added (split from maor1246: both with numeral system “decimal proper”); and (5) ngga1239 is added (with numeral system “unknown”).

&nbsp; | Value | Count | Description
--- | --- | ---:| ---
$${\color{red}⏺}$$ | decimal proper | 632 | A decimal system with atomic numerals ‘one’ through ‘nine’.
$${\color{orange}⏺}$$ | decimal modified | 228 | A decimal system with one or more derived numerals lower than ‘ten’.
$${\color{yellow}⏺}$$ | quinary | 290 | A system that constructs numerals based on the number 5.
$${\color{blue}⏺}$$ | binary proper | 22 | A system that constructs the numerals ‘three’ and ‘four’ based on the number 2.
$${\color{purple}⏺}$$ | binary+3 | 14 | A system that constructs the numeral ‘four’ based on the number 2 but has an atomic ‘three’
$${\color{purple}⏺}$$ | binary+3 | 14 | A system that constructs the numeral ‘four’ based on the number 2 but has an atomic ‘three’.
$${\color{black}⏺}$$ | quaternary | 5 | A system that constructs numerals based on the number 4.
$${\color{gray}⏺}$$ | unknown | 83 | An unknown numeral system.
&nbsp; | &nbsp; | **1274** | &nbsp;

&nbsp; | Value | Count | Description
---:| --- | ---:| ---
⏺| in Melanesia | 514 |
▼| not in melanesian | 760 |
▼| not in Melanesia | 760 |

![num_syst](num_syst.svg)

Expand Down
2 changes: 1 addition & 1 deletion maps/colex.html

Large diffs are not rendered by default.

Loading

0 comments on commit cfbe197

Please sign in to comment.