{"id":21010889,"url":"https://github.com/miserman/lingmatch","last_synced_at":"2025-05-15T03:32:04.631Z","repository":{"id":56934180,"uuid":"104701374","full_name":"miserman/lingmatch","owner":"miserman","description":"An all-in-one R package for the assessment of linguistic similarity","archived":false,"fork":false,"pushed_at":"2024-11-08T20:51:07.000Z","size":31062,"stargazers_count":11,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2024-11-08T21:33:58.568Z","etag":null,"topics":["nlp","r","rcpp","text-analysis"],"latest_commit_sha":null,"homepage":"https://miserman.github.io/lingmatch","language":"R","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/miserman.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-09-25T03:55:10.000Z","updated_at":"2024-11-08T20:51:12.000Z","dependencies_parsed_at":"2023-02-12T18:00:56.251Z","dependency_job_id":"aa9a4c04-200b-443c-a6e4-19a38aa9727a","html_url":"https://github.com/miserman/lingmatch","commit_stats":{"total_commits":137,"total_committers":2,"mean_commits":68.5,"dds":0.4014598540145985,"last_synced_commit":"022dce57b99ef52155e17fccc1640090a9373b75"},"previous_names":[],"tags_count":8,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/miserman%2Flingmatch","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/miserman%2Flingmatch/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/miserman%2Flingmatch/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/miserman%2Flingmatch/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/miserman","download_url":"https://codeload.github.com/miserman/lingmatch/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":225325379,"owners_count":17456706,"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","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":["nlp","r","rcpp","text-analysis"],"created_at":"2024-11-19T09:24:18.769Z","updated_at":"2024-11-19T09:24:19.398Z","avatar_url":"https://github.com/miserman.png","language":"R","funding_links":[],"categories":[],"sub_categories":[],"readme":"# lingmatch\nAn all-in-one R package for the assessment of linguistic matching and/or accommodation.\n\n## features\n\n* Input raw text, a document-term matrix (DTM), or LIWC output.\n* Apply various weighting functions to a DTM.\n* Measure similarity and/or accommodation with various metrics.\n* Calculate standard forms of Language Style Matching (LSM) and Latent Semantic Similarity (LSS).\n\n## resources\n* Documentation and guides: [miserman.github.io/lingmatch](https://miserman.github.io/lingmatch/)\n  * [Quick Start](https://miserman.github.io/lingmatch/articles/quickstart.html)\n  * [Comparison Specification](https://miserman.github.io/lingmatch/articles/groups.html)\n  * [Introduction to Text Analysis](https://miserman.github.io/lingmatch/articles/introduction.html)\n  * [Word Vectors](https://miserman.github.io/lingmatch/articles/word_vectors.html)\n  * [Text Classification](https://miserman.github.io/lingmatch/articles/text_classification.html)\n  * [Dictionary Creation](https://miserman.github.io/lingmatch/articles/dictionary_creation.html)\n* Dictionary repository: [osf.io/y6g5b](https://osf.io/y6g5b/wiki/home/)\n* Latent semantic space repository: [osf.io/489he](https://osf.io/489he/wiki/home/)\n* Dictionary builder: [miserman.github.io/dictionary_builder](https://miserman.github.io/dictionary_builder/)\n\n## installation\nDownload R from [r-project.org](https://www.r-project.org/), then install the package from an R console:\n\nRelease ([version 1.0.7](https://CRAN.R-project.org/package=lingmatch))\n```R\ninstall.packages(\"lingmatch\")\n```\nDevelopment (version 1.0.8)\n```R\n# install.packages(\"remotes\")\nremotes::install_github(\"miserman/lingmatch\")\n```\n\nAnd load the package:\n```R\nlibrary(lingmatch)\n```\n## examples\nCan make a quick comparison between two bits of text; by default this will give the cosine similarity between raw\nword-count vectors:\n```R\nlingmatch(\"First text to look at.\", \"Text to compare that text with.\")\n```\n\nOr, given a vector of texts:\n```R\ntext = c(\n  \"Why, hello there! How are you this evening?\",\n  \"I am well, thank you for your inquiry!\",\n  \"You are a most good at social interactions person!\",\n  \"Why, thank you! You're not all bad yourself!\"\n)\n```\nProcess the texts in one step:\n```R\n# with a dictionary\ninquirer_cats = lma_process(text, dict = \"inquirer\", dir = \"~/Dictionaries\")\n\n# with a latent semantic space\nglove_vectors = lma_process(text, space = \"glove\", dir = \"~/Latent Semantic Spaces\")\n```\n\nOr process the texts step by step, then measure similarity between each:\n```R\ndtm = lma_dtm(text)\ndtm_weighted = lma_weight(dtm)\ndtm_categorized = lma_termcat(dtm_weighted, lma_dict(1:9))\nsimilarity = lma_simets(dtm_categorized, metric = \"canberra\")\n```\n\nOr do that within a single function call:\n```R\nsimilarity = lingmatch(\n  text, weight = \"frequency\", dict = lma_dict(1:9), metric = \"canberra\"\n)$sim\n```\n\nOr, if you want a standard form (as in this example), specify a default:\n```R\nsimilarity = lingmatch(text, type = \"lsm\")$sim\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmiserman%2Flingmatch","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmiserman%2Flingmatch","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmiserman%2Flingmatch/lists"}