MScore: Risk Scores Made Easy
Reason this release was yanked:
SourceDefender incompatible
Project description
MSCORE® is a python package designed to streamline the CMS-HCC model risk score calculation process for health plans and providers participating in Medicare Advantage and value-based care. It provides a SAS®-free alternative to produce HCCs and risk scores. It streamlines your data processing for enhanced accessibility and allows you to keep your data secure in-house, so you can focus on execution of your risk adjustment strategy.
Benefits
-
Implement Anywhere: MSCORE® unlocks multiple integration opportunities including real-time scoring, embedding in EHR or enterprise data warehouse, incorporating into cloud applications, and traditional batch scoring.
-
SAS®-Free: Create HCC and risk scores without SAS® software, reduce software license costs and the headache of recoding and maintaining the software in another programming language.
-
Enhanced Output: MSCORE® provides the numeric relative factor value for each HCC assigned to a person allowing for a deeper understanding of how each factor contributes to an individual's overall risk score.
-
Reliable: Validated on over 1 million plus enrollees. MSCORE® is rigorously tested and updated with each HCC model release.
-
CMS-HCC Model Support: Supports HCC models V22 for payment years 2021-2027(Proposed), V24 for payment years 2021 - 2026, and V28 for payment years 2024 - 2027(Proposed), with upgrades for each release from CMS (Initial, Mid-Year, Final).
- NOTE: 2027 Proposed is set with an 'as of' date in year 2025
-
Easy to Set Up & Maintain: Easily installed and upgraded using pip, Python's standard package manager.
-
Platform Compatibility: Compatible with Windows, Mac, and Linux operating systems.
-
Optimized Performance: Efficient processing with fast runtimes, ensuring quick and accurate risk score calculations.
-
Improved Data Security: Securely process personal health information within your organization's IT infrastructure.
Installation
pip install mscore
Registration
Registration is required to use the mscore package. Please visit https://riskadjustmentmodel.com/registration to create user account and obtain a license key.
NOTE: Your 30-day free trial begins upon account registration.
Subscribe
To use MSCORE® beyond the 30-day trial period, please see our licensing and pricing section on riskadjustmentmodel.com. Please contact us for assistance if you have questions about licensing.
Basic Use
Before you can run your scores, you will need to generate an authorization token object.
import sourcedefender #This package is required at the top
from mscore import AuthorizeLicense, MScore
auth = AuthorizeLicense(staging_key).validate()
NOTE: You must import sourcedefender at the top of every package that imports MScore.
The mscore class requires 7 arguments in order to run with 1 optional argument.
Required
authorizer- The authorization token obtained whenAuthorizeLicenseis ranyearversionmodelperson_data(Pandas DataFrame, csv, or parquet file)diag_data(Pandas DataFrame, csv, or parquet file)columns
NOTE: The example below assumes you already have a Pandas DataFrame generated for your person and diagnosis datasets.
If you don't have this data yet and want to test mscore, download our synthetic data files here:
import sourcedefender
import pandas as pd
from mscore import AuthorizeLicense, MScore
# Generate DataFrames if using our test files
person_df = pd.read_csv('person.csv')
diag_df = pd.read_csv('diag.csv')
auth = AuthorizeLicense(staging_key).validate()
model = MScore(
authorizer = auth,
year = '2026',
version = 'V28',
model = 'CMS-HCC',
person_data = person_df,
diag_data = diag_df,
columns = 'all-fields',
)
scores = model.score_mscore()
risk_scores = scores.risk_scores
The resulting 'scores' output is a data model object of pandas.DataFrames. You can access your risk scores or relative factors data sets by calling the respective model name from the grouped data model.
- scores.risk_scores
- scores.relative_factors
From here you can proceed to use the risk score or relative factor DataFrames for further downstream processing or utilize the Pandas built-in methods to save to a file type of your choosing.
Features
relative_factors (attribute)
MScore offers the ability to view the relative factors for each person run through MSCORE®. To access this data, you simply access the relative_factors attribute of the mscore output. The relative factors are the individual contributions (from the variables in the model) to the risk score. MSCORE's® relative_factors output contains these values with 1 row per person scored, and each relative factor in the output as the columns.
To leverage this feature, you would do the following:
relative_factors = scores.relative_factors
get_disease_scores (method)
For users wanting to compute the disease contribution to a person's risk score, you can do this in MScore by using the get_disease_score method of mscore. After instantiating your mscore object, you can use get_disease_score and pass the mscore output as a parameter. This will create a new dataframe containing only the portion of the risk score that comes from disease factors. Alternatively, if you would like this data appended to your MScore risk score output, you can use join_scores parameter to do this. NOTE: Disease interactions with DISABLED variables are not included in the disease score.
You can use the get_disease_score method as here:
disease_scores = model.get_disease_scores(scores)
Or using the join_scores parameter:
disease_scores = model.get_disease_scores(scores, join_scores=True)
Supported Data
The mscore class attributes, person_data and diag_data, will accept a Pandas.DataFrame object, CSV or Parquet filepath directly without the need to load your input data to DataFrame first. The resulting outputs will be a Pandas DataFrame object.
Supported Environments
MSCORE® is designed to be universally compatible, ensuring seamless integration across various platforms.
- Operating Systems: Windows, macOS, Linux
- Python Versions: 3.10 or greater (both 32-bit and 64-bit architectures)
If your required environment is not listed, please contact us as support@riskadjustmentmodel.com for an alternate solution.
User Resources
For a more in-depth dive into all available model options, arguments, and reference documents, visit our User Guides.
Support
We are experts in Risk Adjustment and we're here to help. Whether it's general questions, billing, or integration support, please contact us📧. We are here to make risk scoring easy.
Stay Connected
Please subscribe to our newsletter, to receive updates on new MSCORE® features, model releases, tutorials, and to stay up-to-date on the latest news in risk adjustment.
Legal
To review the MSCORE® license agreement, please visit EULA webpage.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
File details
Details for the file mscore-26.1.6.tar.gz.
File metadata
- Download URL: mscore-26.1.6.tar.gz
- Upload date:
- Size: 2.1 MB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
38dd98858e22c3a0f1bef8b6b1985202107cf24f5dddac33a60c6abcf5beaffa
|
|
| MD5 |
a2a95b230534114b965eec220c29e816
|
|
| BLAKE2b-256 |
03df1e924f0272f95160f1060285a5bb0f168b836a2c6cd79dbfd6e9c8b6405a
|