{"id":17287646,"url":"https://github.com/zuphilip/csl-analysis","last_synced_at":"2026-02-12T10:31:43.920Z","repository":{"id":84027045,"uuid":"89858716","full_name":"zuphilip/csl-analysis","owner":"zuphilip","description":null,"archived":false,"fork":false,"pushed_at":"2017-05-01T18:21:47.000Z","size":3647,"stargazers_count":1,"open_issues_count":2,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-06-04T07:50:20.250Z","etag":null,"topics":["citation-style-language"],"latest_commit_sha":null,"homepage":"","language":"XQuery","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/zuphilip.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-04-30T15:21:18.000Z","updated_at":"2025-02-24T18:45:30.000Z","dependencies_parsed_at":"2023-04-09T03:33:52.990Z","dependency_job_id":null,"html_url":"https://github.com/zuphilip/csl-analysis","commit_stats":{"total_commits":10,"total_committers":2,"mean_commits":5.0,"dds":"0.19999999999999996","last_synced_commit":"dbeae87f02dff921e72378477a720479f3b4d130"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/zuphilip/csl-analysis","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zuphilip%2Fcsl-analysis","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zuphilip%2Fcsl-analysis/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zuphilip%2Fcsl-analysis/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zuphilip%2Fcsl-analysis/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/zuphilip","download_url":"https://codeload.github.com/zuphilip/csl-analysis/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zuphilip%2Fcsl-analysis/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":271462094,"owners_count":24763858,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-21T02:00:08.990Z","response_time":74,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["citation-style-language"],"created_at":"2024-10-15T10:03:56.300Z","updated_at":"2026-02-12T10:31:43.913Z","avatar_url":"https://github.com/zuphilip.png","language":"XQuery","funding_links":[],"categories":[],"sub_categories":[],"readme":"# CSL Analysis\n\nIn the subfolders are some scripts and tools for an analysis\nthe styles of the Citation Style Language (CSL). These scripts\nare in some standard formats, e.g. XQuery, and can be reuse\nhopefully easily in various ways. However, we describe here\nour technology stack to work with this scripts as one example:\n\n## CSL Styles\n\nStart with cloning the current csl styles:\n```\ngit clone https://github.com/citation-style-language/styles.git\n```\nThis gives you the most recent version of the styles. If you want\nto work with an older snapshot you can simply `git checkout` it.\n\n## baseX\n\n1. Download and install [baseX](http://basex.org/) for performing the\nXQueries.\n2. Open baseX\n3. Create a new database (Database\u003eNew...)\n   1. Select the csl styles directory\n   2. Choose a reasonable name, e.g. `csl-styles`\n   3. Change the file patterns to `*.csl`, cf. with [this picture](img/basex-new-database.jpg)\n   4. Click `Ok`\n4. Open the XQuery files `.xq` from the subfolder `xquery` you are\ninterested in (Editor\u003eOpen...)\n\n![basex-new-database](img/basex-csl-example.png)\n\n## Open Refine\n\nWe use [Open Refine](http://openrefine.org/) for enrichting\nour data with the help of the\n[SRU interface of the ZDB](http://www.zeitschriftendatenbank.de/services/schnittstellen/sru/),\nwhich stores informations about journals. Especially we are\ninterested in the\n[main DDC groups](http://www.dnb.de/SharedDocs/Downloads/DE/DNB/service/ddcSachgruppenDNB.pdf?__blob=publicationFile)\nfor a information about the discipline of the journal.\n\n1. Download and install [Open Refine](http://openrefine.org/).\n2. Open the result of the `csl-basic-statistics.xq` TODO w/o Excel\n3. Create a new column which calls the URLs and download the\nresult as XML data. !!For the whole data this took at least 1 hour!!\n   1. Create new column based on some column\n   2. Use this GREL\n   ```\n   \"http://services.dnb.de/sru/zdb?version=1.1\u0026operation=searchRetrieve\u0026recordSchema=MARC21-xml\u0026query=dnb.iss%3D\"  + cells.issn.value + \"+OR+\" + cells.eissn.value\n   ```\n   3. Change the waiting time between several requests\n   4. Start\n   5. Wait...\n4. Create a new column for extracting the DDC info\n   1. Create a new column based on the previous column with the xml data\n   2. Use this GREL\n   ```\n   uniques(forEach(value.parseHtml().select('datafield[tag=082]\u003esubfield[code=a]'), v, htmlText(v))).join(\", \")\n   ```\n   3. Click `OK`\n5. Create a text facet from the row `ddc`\n6. Cluster it to merge the same combinations with different order\n7. Explore further..\n\n![open refine](img/open-refine.png)\n\nOur current output from this is saved as a CSV file at [open-refine/csl-analysis.csv](open-refine/csl-analysis.csv).\n\n## Gephi\n\n1. Download and install [Gephi](https://gephi.org/).\n2. Open Gephi, create a `New Project`\n3. Go to the `Data Labratory`\n   1. click on `Import spreadsheet`\n   2. Choose `open-refine/csl-analysis.csv` as the `Nodes table`\n   3. In the `Import Settings` choose `Integer` as type for `#depend`\n   4. Click `Finish`\n4. Delete the nodes corresponding to dependent styles, i.e. where `#depend` is `-1`.\n5. Open `csl-template.csv` with your text editor and add `Source,Target` as your first line.\n6. Click again on `Import spreadsheet`, select the adapted [`csl-template.csv`](gephy/csl-template-with-header.csv) as the `Edge table`.\n7. Switch to the `Overview` tab\n8. Click on `Statistics` and run the detection of the `Connected Components`, afterwards you can in the `Filter` tab filter on the size of the connected componentent (`Partition Count` and choose `Partition ID`). In this way you can filter out single nodes or small components of just a handful nodes to see the big picture.\n9. `Appearance\u003eNodes\u003eColor\u003ePartition` choose for example `ddc-first`\n10. `Appearance\u003eNodes\u003eSize\u003eRanking` choose for example `#depend`\n11. TODO labels\n12. For export make sure that you have activated the labels also in the `Preview` tab\n\n![gephi](img/gephi.png)\n\nSee [gephi/graph.png](gephi/graph.png) for the current output.\n\n## pivottable\n\nUsing the JavaScript implementation with drag'n'drop https://github.com/nicolaskruchten/pivottable for our exploring our data.\n\n* code: [docs](docs)\n* result: https://zuphilip.github.io/csl-analysis/\n\n(Hint: For your own local csv files try this: http://nicolas.kruchten.com/pivottable/examples/local.html)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzuphilip%2Fcsl-analysis","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fzuphilip%2Fcsl-analysis","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzuphilip%2Fcsl-analysis/lists"}