Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request: logarithmic (continuous) color scale #744

Closed
simleb opened this issue Nov 10, 2015 · 2 comments · Fixed by #763
Closed

Feature request: logarithmic (continuous) color scale #744

simleb opened this issue Nov 10, 2015 · 2 comments · Fixed by #763

Comments

@simleb
Copy link
Contributor

simleb commented Nov 10, 2015

A logarithmic continuous color scale would be nice to have.

Consistently with Scale.x_continuous and Scale.y_continuous, a number of transformed continuous scales could be provided:

  • Scale.color_continuous (scale without any transformation).
  • Scale.color_log10
  • Scale.color_log2
  • Scale.color_log
  • Scale.color_asinh
  • Scale.color_sqrt
@durcan
Copy link

durcan commented Nov 17, 2015

I brought up some trouble I was having implementing exactly this functionality in #573. I agree that colors currently are in need of some attention, both in scalings as well as optional, built-in colormaps.

@tbreloff
Copy link
Contributor

It doesn't directly solve your request, but here's how you could customize using Plots.jl:

julia> using Plots, RDatasets; gadfly();

julia> d = dataset("ggplot2", "diamonds");

julia> hexbin(d, :Price, :Carat,
              nbins=70,
              size=(500,500),
              c=colorscheme(:heat, [0,0.01,1]),
              bg=:black)

julia> png("/home/tom/tmp")

tmp

One caveat is that you'll need to do a Pkg.checkout("Plots") for it to work properly, as I've recently fixed a bug.

simleb added a commit to simleb/Gadfly.jl that referenced this issue Dec 7, 2015
@simleb simleb mentioned this issue Dec 7, 2015
simleb added a commit to simleb/Gadfly.jl that referenced this issue Dec 18, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants