Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

cgmzscore

Package Overview
Dependencies
Maintainers
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

cgmzscore

z-scores of anthropometric measurements of children below 5 years based on WHO

  • 3.3.1
  • PyPI
  • Socket score

Maintainers
2

Z score

This libray is Used for measuring Z score of Children (0-5 Years) based on standard provided by WHO 2006

.. image:: https://img.shields.io/pypi/v/cgmzscore.svg :target: https://pypi.org/project/cgmzscore/ :alt: Latest Version

.. image:: https://img.shields.io/pypi/wheel/cgmzscore.svg :target: https://pypi.org/project/cgmzscore/

.. image:: https://img.shields.io/pypi/pyversions/cgmzscore.svg :target: https://pypi.org/project/cgmzscore/

.. image:: https://snyk.io/advisor/python/banner/badge.svg :target: https://snyk.io/advisor/python/banner :alt: banner

REQUIREMENTS

  • Python 2.7.x, Python 3.x or later

INSTALLATION

pip install cgmzscore

EXAMPLE USAGE

applying functions on CGM datasets:

.. code-block:: python

from cgmzscore.src.main import z_score_with_class
import ast

df["sex"] = df["sex"].map({"male": "M", "female": "F"})
df["metrics"] = df.apply(lambda row: z_score_with_class(weight=row["weight"], height=row["height"], muac=row["muac"], age_in_days=row["age"], sex=row["sex"]), axis=1)
df["metrics"] = df["metrics"].apply(ast.literal_eval)
for col in df.metrics[0].keys():
    df[col] = df["metrics"].apply(lambda x: x[col])
df = df.drop("metrics", axis=1)

calculate z score for weight vs age

.. code-block:: python

from cgmzscore.src.main import z_score_wfa

score = z_score_wfa(weight="7.853",age_in_days='16',sex='M')

calculate z score for weight vs length/height

.. code-block:: python

from cgmzscore.src.main import z_score_wfl

score = z_score_wfl(weight="7.853",age_in_days='16',sex='M',height='73')

calculate z score for weight vs length/height and both wfl and wfh works same

.. code-block:: python

from cgmzscore.src.main import z_score_wfh

score = z_score_wfh(weight="7.853",age_in_days='16',sex='M',height='73')

calculate z score for length vs age

.. code-block:: python

from cgmzscore.src.main import z_score_lhfa

score = z_score_lhfa(age_in_days='16',sex='M',height='73')

compute all z scores and corresponding diagnoses at once

.. code-block:: python

from cgmzscore.src.main import z_score_with_class

score = z_score_with_class(weight="7.853", muac="13.5", age_in_days='16', sex='M', height='73')

FAQs


Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc