Scale.y_continuous
Map numerical data to y positions in cartesian coordinates.
Arguments
minvalue: Set scale lower bound to be ≤ this value.maxvalue: Set scale lower bound to be ≥ this value.
minvalue and maxvalue here are soft bounds, Gadfly may choose to ignore them when constructing an optimal plot. Use Coord.cartesian to enforce a hard bound.
labels: Either aFunctionornothing. When a function is given, values are formatted using this function. The function should map a value inxto a string giving its label. If the scale applies a transformation, transformed label values will be passed to this function.format: How numbers should be formatted. One of:plain,:scientific,:engineering, or:auto. The default in:autowhich prints very large or very small numbers in scientific notation, and other numbers plainly.scalable: When set to false, scale is fixed when zooming (default: true)
Variations
A number of transformed continuous scales are provided.
Scale.y_continuous(scale without any transformation).Scale.y_log10Scale.y_log2Scale.y_logScale.y_asinhScale.y_sqrt
Aesthetics Acted On
y, ymin, ymax, yintercept
Examples
# Transform both dimensions
plot(x=rand(10), y=rand(10), Scale.y_log)
# Force the viewport
plot(x=rand(10), y=rand(10), Scale.y_continuous(minvalue=-10, maxvalue=10))
# Use scientific notation
plot(x=rand(10), y=rand(10), Scale.y_continuous(format=:scientific))
# Use manual formatting
plot(x=rand(10), y=rand(10), Scale.y_continuous(labels=y -> @sprintf("%0.4f", y)))