Skip to content

Instantly share code, notes, and snippets.

View SuzanaK's full-sized avatar

Suzana K. SuzanaK

View GitHub Profile
@SuzanaK
SuzanaK / pytest.md
Last active November 8, 2020 15:40 — forked from kwmiebach/pytest.md
pytest cheat sheet

Usage

(Create a symlink pytest for pytest)

pytest [options] [file_or_dir] [file_or_dir] ...

Help:

@SuzanaK
SuzanaK / bantu_languages.json
Created November 8, 2015 23:12
Bantu Language data in JSON format. Data sources: Wikipedia, Glottolog. Data Fields: speakers, glottolog code, name, Guthrie classification, geographic coordinates, Wikipedia page, countries where the language is native, Wikipedia categories, steps how far the language is descended from the original Bantu language.
[{"speakers": "24100", "code": "akwa1248", "name": "Akwa", "guthrie": "C.22", "long": 15.4623, "steps": 5, "lat": -0.39897, "iso": "akw", "wikipedia_page_ID": "35515400", "native": "", "categories": "Mboshi-Buja languages, Mboshi languages, Mboshi languages, Languages of the Republic of the Congo, Bantu language stubs", "spoken_in": "Republic_of_the_Congo"}, {"speakers": "40100", "code": "amba1263", "name": "Amba", "guthrie": "D.22, D.20B", "long": 30.0014, "steps": 6, "lat": 0.81206, "iso": "rwm", "wikipedia_page_ID": "27745809", "native": "Kwamba", "categories": "Boan languages, Biran languages, Languages without ISO 639-3 code but with Guthrie code, Languages of the Democratic Republic of the Congo, Languages of Uganda, Biran languages, Bantu language stubs", "spoken_in": "Democratic_Republic_of_the_Congo, Uganda"}, {"speakers": "widespread as L2 in DR Congo", "code": "aush1241", "name": "Aushi", "guthrie": "M.402", "long": 29.0168, "steps": 8, "lat": -11.6295, "iso": "auh", "wikipedia_page_ID": "35730752"
@SuzanaK
SuzanaK / languages_geo.json
Last active November 9, 2015 16:39
Language names, iso codes, and geographic coordinates (longitude, latitude) for 587 languages of the world, including sign languages. Glottolog's Licence applies (Creative Commons Attribution-Sharealike 3.0 Unported License).
[{"name": "Abe", "long": "5.59682", "iso2": "", "iso": "aba", "lat": "-4.38497", "iso_jw": "aba", "iso3b": ""}, {"name": "Abkhazian", "long": "42.2334", "iso2": "ab", "iso": "abk", "lat": "41.2963", "iso_jw": "ab", "iso3b": ""}, {"name": "Abua", "long": "4.83057", "iso2": "", "iso": "abn", "lat": "6.61492", "iso_jw": "abn", "iso3b": ""}, {"name": "Inabaknon", "long": "12.4264", "iso2": "", "iso": "abx", "lat": "124166", "iso_jw": "abx", "iso3b": ""}, {"name": "Abui", "long": "-8.31058", "iso2": "", "iso": "abz", "lat": "124588", "iso_jw": "abz", "iso3b": ""}, {"name": "Saint Lucian Creole French", "long": "15.3947", "iso2": "", "iso": "acf", "lat": "-61.3641", "iso_jw": "acf", "iso3b": ""}, {"name": "Acoli", "long": "3.57738", "iso2": "", "iso": "ach", "lat": "32.5147", "iso_jw": "ach", "iso3b": ""}, {"name": "Achi", "long": "15073", "iso2": "", "iso": "acr", "lat": "-90.3513", "iso_jw": "acr", "iso3b": ""}, {"name": "Adangme", "long": "5.9437", "iso2": "", "iso": "ada", "lat": "0.13243", "iso_jw": "ada", "is
#! /bin/bash
if [ "$1" ] ; then exec < "$1" ; fi
test "$1" && exec < "$1"
echo $1
@SuzanaK
SuzanaK / googleit.sh
Last active August 29, 2015 14:21
script to automatically google error messages printed to STDERR, using firefox
#! /bin/bash
usage="\nWill google the error message from COMMAND, using Firefox.
\nUsage: COMMAND |& $0 \n or COMMAND 2>&1 >/dev/null | $0 (to silence STDIN) \n or $0 ERROR_MESSAGE"
if [ "$*" ] ; then
input="$*"
else
read -t0.2 -d'' -r input
fi
@SuzanaK
SuzanaK / README.md
Last active March 13, 2017 08:26
World map with languages of jw.org

Map of languages from jw.org (July 2014)

This visualisation does not contain all languages from jw.org (644 in July 2014) but only those where the Glottolog entry contains the geographical coordinates (587 languages).

Each circle contains a hyperlink to the corresponding publications on jw.org.

Map data from MBostock's TopoJSON, language data from Glottolog, languages from jw.org/en/publications, color palette from this ColourLovers palette.

You can scroll and move the map with the mouse.

@SuzanaK
SuzanaK / README.md
Last active August 29, 2015 14:03
Guthrie's Classification of Bantu Languages

Guthrie's Classification of Bantu Languages

This visualisation does not contain all Bantu languages but only those where the Wikipedia article contains the Guthrie classification.

White circles are languages without Guthrie code or where the Guthrie code has not been entered yet into DBPedia.

Each circle contains a hyperlink to the corresponding Wikipedia article.

Map data from MBostock's TopoJSON, language data from Glottolog and DBPedia.

@SuzanaK
SuzanaK / README.md
Last active August 29, 2015 14:03
D3.js Map Visualization of References to Bantu Languages

D3.js Map Visualization of Bantu (Narrow Bantoid) Languages.

The darker the color, the more linguistic publications exist for this language. The most referenced language is Suaheli (1936 references).

Map data from MBostock's TopoJSON, language data from Glottolog.

@SuzanaK
SuzanaK / README.md
Last active August 29, 2015 14:03 — forked from mbostock/.block
Color grid example of d3.js animated transformations

D3 2.5.0 supports matrix decomposition for animating 2D transforms. Any SVG transform attribute is decomposed into a canonical representation of translate, rotate, scale and skew. This allows two arbitrary transforms of different types to be transitioned smoothly—say from a simple translate to a scale plus rotate. These features are supported automatically by your browser for CSS3 transitions, but now you can have them in JavaScript for SVG, too!

@SuzanaK
SuzanaK / README.md
Last active August 29, 2015 14:03
Map Visualization of Bantu Languages

Map Visualization of Bantu (Narrow Bantoid) Languages.

The darker the color, the more "ancient" the language (more direct descendent of the original Proto-Bantu language).

Map data from MBostock's TopoJSON, language data from Glottolog. You can zoom in with the mouse wheel and move the map. A click on a language will open a link to its Glottolog page.