# 20.6 Gradient, Rules आणि Field value

Source: https://ravindrabagale.com/mr/powerbi/ch20-dynamic-text-and-dynamic-colour-conditional/20-6-conditional-formatting-rules-gradient-and-field.html
Language: mr (Marathi with English technical terms)

| Style | कसं काम? | उदाहरण

 | Gradient | Value rangeनुसार colour scale | कमी delivery time green, जास्त red

 | Rules | Thresholdनुसार colours | ≤10 green;10–15 amber;>15 red

 | Field value | Measure hex / colour देतो | Reusable Delivery Time Colour

Delivery Time Colour =
VAR t = [Avg Delivery Time (mins)]
RETURN
SWITCH(TRUE(),
    ISBLANK(t), BLANK(),
    t <= 10, "#107C10",     -- green
    t <= 15, "#F2A900",     -- amber
    "#D13438")              -- red: slower than 15 minutes

Store Name, Orders, Avg Time, Cancellation table बनवा.

Avg Time field dropdown › Conditional formatting › Background; किंवा Cell elementsमध्ये त्या columnला fx.

Rules, Values only, based on Avg Time measure.

0–10 green, >10–15 amber, >15 red. Maximum999सारखी arbitrary सीमा असेल तर त्यापुढच्या valuesचाही rule ठेवा.

पर्याय: Field value › Delivery Time Colour measure.

Backgroundशी contrast जुळवण्यासाठी font-colour measure वापरता येतो.

Blank valuesला don’t format किंवा neutral colour द्या. Deliveryच नाही असा store perfect green दिसू नये.

रवींद्र बागले यांची tip

Low is good की High is good हे आधी ठरवा. एक reusable colour measureमुळे अनेक visualsचे thresholds सुसंगत राहतात.
