LogScale
public class LogScale : ScaleLogarithmic scale for exponential data.
Constructors
Section titled “Constructors”
LogScale(float, float, float, float)
Section titled “LogScale(float, float, float, float)”public LogScale(float domainMin = 1, float domainMax = 100, float rangeMin = 0, float rangeMax = 1)Creates a base-10 logarithmic scale, replacing non-positive domain bounds with safe positive defaults.
Parameters
| Name | Type |
|---|---|
domainMin |
System.Single |
domainMax |
System.Single |
rangeMin |
System.Single |
rangeMax |
System.Single |
Methods
Section titled “Methods”
SetBase(float)
Section titled “SetBase(float)”public LogScale SetBase(float logBase)Sets the logarithm base used for mapping, inversion, and tick generation.
Parameters
| Name | Type |
|---|---|
logBase |
System.Single |
Returns
ChartGuru.LogScale
Map(float)
Section titled “Map(float)”public override float Map(float value)Maps a value from the scale’s input domain into its configured output range.
Parameters
| Name | Type |
|---|---|
value |
System.Single |
Returns
System.Single
Invert(float)
Section titled “Invert(float)”public override float Invert(float position)Reverses the axis mapping so larger values are laid out toward the opposite edge.
Parameters
| Name | Type |
|---|---|
position |
System.Single |
Returns
System.Single
GenerateTicks(int)
Section titled “GenerateTicks(int)”public override float[] GenerateTicks(int count)Generates readable tick values spanning the active domain, targeting the requested count without exceeding scale constraints.
Parameters
| Name | Type |
|---|---|
count |
System.Int32 |
Returns
System.Single[]