{"id":19056972,"url":"https://github.com/gabrielrufino/samplesize","last_synced_at":"2025-04-24T05:20:56.029Z","repository":{"id":38182706,"uuid":"417849009","full_name":"gabrielrufino/samplesize","owner":"gabrielrufino","description":"📊 Package to determine the ideal sample size for a survey","archived":false,"fork":false,"pushed_at":"2025-04-16T22:05:30.000Z","size":1352,"stargazers_count":0,"open_issues_count":1,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-04-17T10:13:24.759Z","etag":null,"topics":["math","mathmatics","samplesize","statistics"],"latest_commit_sha":null,"homepage":"https://samplesize.gabrielrufino.com","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"unlicense","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/gabrielrufino.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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,"zenodo":null}},"created_at":"2021-10-16T14:17:19.000Z","updated_at":"2025-03-15T01:15:08.000Z","dependencies_parsed_at":"2023-01-30T20:16:08.516Z","dependency_job_id":"b51d82a7-ae0b-4bac-8fc3-a871ddd61960","html_url":"https://github.com/gabrielrufino/samplesize","commit_stats":{"total_commits":128,"total_committers":2,"mean_commits":64.0,"dds":0.03125,"last_synced_commit":"bcad273b2100ba1b3153cd3d5deb5512f15c5a6b"},"previous_names":[],"tags_count":35,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gabrielrufino%2Fsamplesize","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gabrielrufino%2Fsamplesize/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gabrielrufino%2Fsamplesize/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gabrielrufino%2Fsamplesize/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gabrielrufino","download_url":"https://codeload.github.com/gabrielrufino/samplesize/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250567585,"owners_count":21451458,"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":["math","mathmatics","samplesize","statistics"],"created_at":"2024-11-08T23:52:54.298Z","updated_at":"2025-04-24T05:20:56.005Z","avatar_url":"https://github.com/gabrielrufino.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cp align=\"center\"\u003e\n  \u003cimg width=\"200px\" src=\"https://drive.google.com/uc?export=view\u0026id=1iuh2NXRaAXMYl0tXL50Km_y-LX36A2Dy\"\u003e\n  \u003ch1 align=\"center\"\u003eSample Size\u003c/h1\u003e\n\u003c/p\u003e\n\n[![Black Tech by Gabriel Rufino](https://img.shields.io/badge/Black_Tech-by_Gabriel_Rufino_%F0%9F%96%A4-white?style=flat-square\u0026labelColor=444444)](https://gabrielrufino.com)\n[![CI](https://github.com/gabrielrufino/samplesize/actions/workflows/ci.yml/badge.svg)](https://github.com/gabrielrufino/samplesize/actions/workflows/ci.yml)\n[![CD](https://github.com/gabrielrufino/samplesize/actions/workflows/cd.yml/badge.svg)](https://github.com/gabrielrufino/samplesize/actions/workflows/cd.yml)\n\nPackage to determine the correct sample size for a survey\n\n### What is Sample Size?\n\nEvery survey needs an ideal number of responses according to the survey's target audience. This is where a statistical calculation that determines the desired sample size comes in.\n\nThe calculation is based on three important variables: population size, confiability rate and margin of error.\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"https://drive.google.com/uc?export=view\u0026id=1jXq8bPiCegwLn065clLgFtnD0ytaFs3l\"\u003e\n\u003c/p\u003e\n\n* **N**: The population size\n* **z**: Score calculated from the confiability rate\n* **e**: Margin of error\n* **p**: Constant, generally 0.5\n\nMore information [here](https://www.surveymonkey.com/mp/sample-size-calculator/).\n\n### Getting started\n\nInstall the package:\n\n```bash\nnpm install @gabrielrufino/samplesize\n```\n\nCalculate the sample size:\n\n```js\nimport SampleSize from '@gabrielrufino/samplesize'\n\nconst size = SampleSize.calculate({\n  population: 3000,\n  confidence: SampleSize.confidences['90%'],\n  errorMargin: 0.05,\n})\n\nconsole.log(size) // 250\n```\n\n### License\n\nUNLICENSED\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgabrielrufino%2Fsamplesize","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgabrielrufino%2Fsamplesize","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgabrielrufino%2Fsamplesize/lists"}