Plots.jl: yflip=true is not working in heatmap plot in GR

Created on 19 Apr 2018  路  22Comments  路  Source: JuliaPlots/Plots.jl

The option stopped working, at least with the GR backend:

heatmap([i for i=1:10, j=1:10], yflip=true)
GR bug

All 22 comments

Also spy I believe (tried yesterday)

heatmap([i for i=1:10, j=1:10], yflip=false)

@daschw yflip=false produces the same output here.

Oh, my bad, for some reason I thought it would default to yflip = true.
However, yflip seems to work for me on Plots master with GR 0.31.0:

heatmap([i for i=1:10, j=1:10])

heatmap_noflip

heatmap([i for i=1:10, j=1:10], yflip=true)

heatmap_flip

Is this not the expected output?

Yes, the output looks correct. The behavior is inverted from previous Plots.jl versions. Maybe a new tag would solve the issue. :+1:

I have Plots v0.17 and GR v0.31 and I don't get the inverted order of the yaxis in the second panel of your example. I get two identical figures looking like your first plot.

I'm on master of both, and get the same output as @daschw . MacOS.

Like @pkofod I have the same versions and can't see the image flipped.

Could you post versioninfo()?

Julia Version 0.6.2
Commit d386e40c17 (2017-12-13 18:08 UTC)
Platform Info:
  OS: macOS (x86_64-apple-darwin14.5.0)
  CPU: Intel(R) Core(TM) i7-5557U CPU @ 3.10GHz
  WORD_SIZE: 64
  BLAS: libopenblas (USE64BITINT DYNAMIC_ARCH NO_AFFINITY Haswell)
  LAPACK: libopenblas64_
  LIBM: libopenlibm
  LLVM: libLLVM-3.9.1 (ORCJIT, broadwell)

I don't think this is a Plots/GR version issue.

I can't reproduce on 0.17. I get the same result as on master.

julia> versioninfo()

Julia Version 0.6.2
Commit d386e40c17* (2017-12-13 18:08 UTC)
Platform Info:
  OS: Linux (x86_64-pc-linux-gnu)
  CPU: Intel(R) Core(TM) i7-6500U CPU @ 2.50GHz
  WORD_SIZE: 64
  BLAS: libopenblas (USE64BITINT DYNAMIC_ARCH NO_AFFINITY Haswell)
  LAPACK: libopenblas64_
  LIBM: libopenlibm
  LLVM: libLLVM-3.9.1 (ORCJIT, skylake)

Pkg.status.(["Plots","GR"])

 - Plots                         0.17.0
 - GR                            0.31.0

mine's identical to @juliohm 's

That's weird:

julia> versioninfo()
Julia Version 0.6.2
Commit d386e40 (2017-12-13 18:08 UTC)
Platform Info:
  OS: Linux (x86_64-pc-linux-gnu)
  CPU: Intel(R) Core(TM) i5-6200U CPU @ 2.30GHz
  WORD_SIZE: 64
  BLAS: libopenblas (DYNAMIC_ARCH NO_AFFINITY Haswell)
  LAPACK: libopenblas
  LIBM: libm
  LLVM: libLLVM-3.9.1 (ORCJIT, skylake)

julia> foreach(Pkg.status, ("Plots", "GR"))
 - Plots                         0.17.0
 - GR                            0.31.0

... same results as shown above

I seem to remember you recently rebuilt GR - might you other two try that?

@mkborregaard I did build GR again with Pkg.build("GR"), the behavior is still the same. Anything else I could do to help debug the issue?

It needs to be ENV["GRDIR"]=""; Pkg.build("GR")

Tried with the env variable as above, still same behavior.

Rebuilt, didn't work. It just flips the axis labels, not the values.

Same here

Julia Version 0.6.3
Commit d55cadc (2018-05-28 20:20 UTC)
Platform Info:
  OS: Linux (x86_64-pc-linux-gnu)
  CPU: Intel(R) Core(TM) i5-4200U CPU @ 1.60GHz
  WORD_SIZE: 64
  BLAS: libopenblas (DYNAMIC_ARCH NO_AFFINITY Haswell)
  LAPACK: libopenblas
  LIBM: libm
  LLVM: libLLVM-3.9.1 (ORCJIT, haswell)

- Plots                         0.17.2
- GR                            0.31.0

Maybe that was implied anyway, but the bug is definitely with GR itself. Directly using it without Plots also does not flip the axis. Using GR from Python gives the same results.

OK, so now yflip stopped working for me on GR:

julia> versioninfo()
Julia Version 0.6.3
Commit d55cadc350* (2018-05-28 20:20 UTC)
Platform Info:
  OS: Windows (x86_64-w64-mingw32)
  CPU: Intel(R) Core(TM) i5-7300U CPU @ 2.60GHz
  WORD_SIZE: 64
  BLAS: libopenblas (USE64BITINT DYNAMIC_ARCH NO_AFFINITY Haswell)
  LAPACK: libopenblas64_
  LIBM: libopenlibm
  LLVM: libLLVM-3.9.1 (ORCJIT, broadwell)

julia> foreach(Pkg.status, ("Plots", "GR"))
 - Plots                         0.17.2+            master
 - GR                            0.31.0

cc @jheinen

Have you tried the current master of GR? The mentioned fix is not part of 0.31.0 and I don't think Plots is using the current master of GR either (at least for me the problem was fixed in the current GR master, but not in Plots master)

Was this page helpful?
0 / 5 - 0 ratings

Related issues

pkofod picture pkofod  路  3Comments

cortner picture cortner  路  4Comments

Cody-G picture Cody-G  路  3Comments

lstagner picture lstagner  路  5Comments

nebuta picture nebuta  路  3Comments