Skip to main content

cjk-data-profiling

cjk-data-profiling is a context-manager package for generating ydata-profiling / fg-data-profiling reports with Japanese, Chinese, or Korean text. It temporarily configures CJK fonts for Matplotlib and WordCloud and prevents report interaction DOM-ID collisions caused by column names.

Installation

pip install cjk-data-profiling

Install the optional profiling dependency when needed:

pip install "cjk-data-profiling[profiling]"

Usage

Wrap report generation in cjk_data_profiling.

import pandas as pd
from data_profiling import ProfileReport

from cjk_data_profiling import cjk_data_profiling

dataframe = pd.DataFrame({"city": ["東京", "大阪"]})

with cjk_data_profiling("ja"):
    report = ProfileReport(dataframe)
    report.to_file("report.html")

Language-specific values are "ja", "zh-cn", "zh-tw", and "ko". Use the additional "mixed" value only when a Noto Sans CJK font is installed; it requires one font that covers Japanese, Chinese, and Korean text.

To prefer a different installed font, replace the candidate list for the relevant language before entering the context. The selected font must include the CJK characters used by the report.

from cjk_data_profiling import FONT_CANDIDATES, cjk_data_profiling

FONT_CANDIDATES["ja"] = ["Yu Gothic", "Meiryo"]

with cjk_data_profiling("ja"):
    ...

The context temporarily changes process-wide Matplotlib and WordCloud defaults, as well as the installed profiling package's report-structure DOM-ID helper. Concurrent report generation from multiple threads in the same process is not supported. Both this package and fg-data-profiling temporarily modify Matplotlib global state while rendering. Do not make this context active in overlapping threads, including with different languages. If reports must be generated concurrently, use separate processes. For threaded applications, serialize the complete report-generation operation with an application-level lock instead.

Testing

pytest
pytest -m integration

Run the non-integration suite on every supported Python version locally:

uv sync --group dev
uv run tox

tox obtains Python 3.11, 3.12, 3.13, and 3.14 through uv, then runs pytest -m "not integration". Report-generation integration tests remain opt-in. The interaction-selector integration test writes *-interaction-selectors.html files to test_output/integration-reports/. Open one in a browser to manually confirm that every Interaction selector, including "a b", "a-b", and CJK column names, displays its matching plot.

Integration reports and WordCloud images are written to test_output/integration-reports/ and are ignored by Git.

Metadata

Release files for cjk-data-profiling 0.1.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for cjk-data-profiling 0.1.2
File Size Uploaded
cjk_data_profiling-0.1.2.tar.gz 6.5 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for cjk-data-profiling 0.1.2
File Interpreter ABI Platform
cjk_data_profiling-0.1.2-py3-none-any.whl Python 3 none any Details

Total release size: 13.7 kB

Release files / cjk_data_profiling-0.1.2.tar.gz

Download URL cjk_data_profiling-0.1.2.tar.gz
Size 6.5 kB
Tags Source
SHA-256 checksum
How to use checksums
69fed5d00c66db89c2dfb09ee767bb142d78fc44b92b2d85ffa03e079ba3ab6d
BLAKE2b-256 checksum
How to use checksums
3fefa0966d92792f787ba9ad5b809b61b99be49782a8fd9a5beb6d237bfb378e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.11.30 {"installer":{"name":"uv","version":"0.11.30","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":null,"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

Release files / cjk_data_profiling-0.1.2-py3-none-any.whl

Download URL cjk_data_profiling-0.1.2-py3-none-any.whl
Size 7.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
ab53a6e6450a697310803da70cfadacfa9a498cb08478fa340a04a5c966b8e71
BLAKE2b-256 checksum
How to use checksums
16f6981394d86fb9e473564cb3f5028aa994cf1f9d6138c757e799b029f74157
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.11.30 {"installer":{"name":"uv","version":"0.11.30","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":null,"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

Release history Release notifications | RSS feed

0.2.0

2 release files

This release

0.1.2 This release

2 release files

0.1.1

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page