rekha.cdfΒΆ
- rekha.cdf(data=None, x=None, color=None, **kwargs)[source]ΒΆ
Create a cumulative distribution function (CDF) plot with Rekha styling.
- Parameters:
data (DataFrame, dict, or None) β The data to plot
x (str, list, array, or None) β Column name or data for CDF
color (str, optional) β Column name for color grouping
facet_col (str, optional) β Column to use for creating subplots (facets)
facet_row (str, optional) β Column to use for creating subplot rows
title (str, optional) β Plot title
labels (dict, optional) β Dictionary mapping column names to display labels
dark_mode (bool, default False) β Whether to use dark theme
figsize (tuple, default (10, 6)) β Figure size (width, height)
grayscale_friendly (bool, default False) β Whether to use distinctive line styles for grayscale printing
**kwargs β Additional styling parameters
- Returns:
CDF plot object with matplotlib figure and axes
- Return type:
Examples
>>> import rekha as rk >>> import pandas as pd >>> import numpy as np >>> df = pd.DataFrame({ ... 'values': np.random.normal(0, 1, 100), ... 'group': ['A'] * 50 + ['B'] * 50 ... }) >>> fig = rk.cdf(df, x='values', color='group', title='CDF Comparison') >>> fig.show()