Skip to content

Stat

marimo.stat

stat(
    value: Union[str, int, float],
    label: Optional[str] = None,
    caption: Optional[str] = None,
    direction: Optional[
        Literal["increase", "decrease"]
    ] = None,
    bordered: bool = False,
) -> Html

Display a statistic.

Optionally include a label, caption, and direction.

PARAMETER DESCRIPTION
value

the value to display

TYPE: Union[str, int, float]

label

the label to display

TYPE: Optional[str] DEFAULT: None

caption

the caption to display

TYPE: Optional[str] DEFAULT: None

direction

the direction of the statistic, either increase or decrease

TYPE: Optional[Literal['increase', 'decrease']] DEFAULT: None

bordered

whether to display a border around the statistic

TYPE: bool DEFAULT: False

RETURNS DESCRIPTION
Html

An Html object representing the statistic.