{"id":15134142,"url":"https://github.com/annndruha/vk_community_distribution","last_synced_at":"2025-09-29T03:30:33.000Z","repository":{"id":37682013,"uuid":"269021306","full_name":"annndruha/vk_community_distribution","owner":"annndruha","description":"vk.com community members sex and age distribution (population pyramid)","archived":true,"fork":false,"pushed_at":"2022-07-22T18:51:44.000Z","size":279,"stargazers_count":5,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-01-19T00:34:59.660Z","etag":null,"topics":["population","population-structure","sociology","vk-api","vkontakte","vkontakte-api"],"latest_commit_sha":null,"homepage":"","language":"Python","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/annndruha.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}},"created_at":"2020-06-03T07:37:03.000Z","updated_at":"2023-09-30T14:23:28.000Z","dependencies_parsed_at":"2022-08-26T02:41:25.613Z","dependency_job_id":null,"html_url":"https://github.com/annndruha/vk_community_distribution","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/annndruha/vk_community_distribution","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/annndruha%2Fvk_community_distribution","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/annndruha%2Fvk_community_distribution/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/annndruha%2Fvk_community_distribution/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/annndruha%2Fvk_community_distribution/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/annndruha","download_url":"https://codeload.github.com/annndruha/vk_community_distribution/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/annndruha%2Fvk_community_distribution/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":277462532,"owners_count":25822032,"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-09-29T02:00:09.175Z","response_time":84,"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":["population","population-structure","sociology","vk-api","vkontakte","vkontakte-api"],"created_at":"2024-09-26T05:02:57.159Z","updated_at":"2025-09-29T03:30:32.696Z","avatar_url":"https://github.com/annndruha.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"## vk.com community members sex and age distribution (population pyramid)\n\n**Скрипт для получения графика и данных распределения участников сообщества вк по полу и возрасту (Возрастно-половая пирамида)**\n\nПример:\n\n![](./example.png)\n\n\n#### Запуск\n+ Установить пакеты из `requirements.txt`\n+ Заменить шаблоны в `secret.json` на свои логин и пароль\n+ Ввести короткую ссылку на сообщество или пользователя в переменную TARGET\n+ Запустить\n+ Данные и график сохранятся в этом же каталоге в одноименной с TARGET папке\n\nПримечание: Да, ввод логина и пароля не самый лучший метод, однако самый простой. Вы можете сами проанализировать мой код и код vk-api чтобы убедиться в их безопастности. Если же вы хотите реализовать метод авторизации Implicit Flow, то я готов к сотрудничеству.\n\n#### Функции\n\nКласс разбит на 4 главных функции:\n\n+ *get_members_ids* - получает id всех участников сообщества или друзей пользователя\n\n+ *get_users_data* - получает данные о возрасте и поле этих id\n\nПоскольку в ВК стоит ограничение на количество вызовов методов api в сутки. То сообщества с огромным количеством пользователей получится проанализировать не чаще пары раз в сутки. Поэтому для экономии запросов, данные об id участников и дополнительные поля сохраняются в виде json в ту же папку. После сохранения данных рекомендую выключить вызов *get_members_ids* и *get_users_data*\n\n+ *calculate* - подсчитывает различиные параметры о пользователях, меняйте на свой усмотрение\n+ *make_plot* - строит гистограмму распределения по полу и возрасту\n\nВ качестве TARGET подойдёт короткая ссылка на сообщество или id пользователя. Не забудьте поменять type group_members / user_friends\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fannndruha%2Fvk_community_distribution","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fannndruha%2Fvk_community_distribution","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fannndruha%2Fvk_community_distribution/lists"}