examples
@ -188,7 +188,7 @@ When plotting multiple lines, you can give every line the same trait by using th
|
|||||||
- [x] Plot vectors/matrices/functions
|
- [x] Plot vectors/matrices/functions
|
||||||
- [ ] Plot DataFrames
|
- [ ] Plot DataFrames
|
||||||
- [ ] Subplots
|
- [ ] Subplots
|
||||||
- [x] Histograms
|
- [ ] Histograms
|
||||||
- [ ] 3D plotting
|
- [ ] 3D plotting
|
||||||
- [ ] Scenes/Drawing
|
- [ ] Scenes/Drawing
|
||||||
- [ ] Graphs
|
- [ ] Graphs
|
||||||
|
|||||||
@ -37,6 +37,12 @@ const examples = PlotExample[
|
|||||||
PlotExample("Build plot in pieces",
|
PlotExample("Build plot in pieces",
|
||||||
"You can add to a plot at any time.",
|
"You can add to a plot at any time.",
|
||||||
[:(plot(rand(100)/3; reg=true, fillto=0)), :(scatter!(rand(100); markersize=6, color=:blue))]),
|
[:(plot(rand(100)/3; reg=true, fillto=0)), :(scatter!(rand(100); markersize=6, color=:blue))]),
|
||||||
|
PlotExample("Heatmaps",
|
||||||
|
"",
|
||||||
|
[:(heatmap(randn(10000),randn(10000); nbins=200))]),
|
||||||
|
PlotExample("Lots of line types",
|
||||||
|
"Options: (:line, :step, :stepinverted, :sticks, :dots, :none, :heatmap, :hexbin, :hist, :bar) \nNote: some may not work with all backends",
|
||||||
|
[:(plot(rand(20,4); linetypes=[:line, :step, :sticks, :dots]))]),
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -59,3 +59,24 @@ scatter!(rand(100); markersize=6,color=:blue)
|
|||||||
|
|
||||||

|

|
||||||
|
|
||||||
|
### Heatmaps
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
```julia
|
||||||
|
heatmap(randn(10000),randn(10000); nbins=200)
|
||||||
|
```
|
||||||
|
|
||||||
|

|
||||||
|
|
||||||
|
### Lots of line types
|
||||||
|
|
||||||
|
Options: (:line, :step, :stepinverted, :sticks, :dots, :none, :heatmap, :hexbin, :hist, :bar)
|
||||||
|
Note: some may not work with all backends
|
||||||
|
|
||||||
|
```julia
|
||||||
|
plot(rand(20,4); linetypes=[:line,:step,:sticks,:dots])
|
||||||
|
```
|
||||||
|
|
||||||
|

|
||||||
|
|
||||||
|
|||||||
@ -59,3 +59,24 @@ scatter!(rand(100); markersize=6,color=:blue)
|
|||||||
|
|
||||||

|

|
||||||
|
|
||||||
|
### Heatmaps
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
```julia
|
||||||
|
heatmap(randn(10000),randn(10000); nbins=200)
|
||||||
|
```
|
||||||
|
|
||||||
|

|
||||||
|
|
||||||
|
### Lots of line types
|
||||||
|
|
||||||
|
Options: (:line, :step, :stepinverted, :sticks, :dots, :none, :heatmap, :hexbin, :hist, :bar)
|
||||||
|
Note: some may not work with all backends
|
||||||
|
|
||||||
|
```julia
|
||||||
|
plot(rand(20,4); linetypes=[:line,:step,:sticks,:dots])
|
||||||
|
```
|
||||||
|
|
||||||
|

|
||||||
|
|
||||||
|
|||||||
|
Before Width: | Height: | Size: 78 KiB After Width: | Height: | Size: 78 KiB |
|
Before Width: | Height: | Size: 28 KiB After Width: | Height: | Size: 23 KiB |
|
Before Width: | Height: | Size: 34 KiB After Width: | Height: | Size: 34 KiB |
|
Before Width: | Height: | Size: 38 KiB After Width: | Height: | Size: 35 KiB |
|
Before Width: | Height: | Size: 48 KiB After Width: | Height: | Size: 49 KiB |
|
Before Width: | Height: | Size: 16 KiB After Width: | Height: | Size: 16 KiB |
|
Before Width: | Height: | Size: 15 KiB After Width: | Height: | Size: 16 KiB |
|
Before Width: | Height: | Size: 11 KiB After Width: | Height: | Size: 11 KiB |
|
Before Width: | Height: | Size: 11 KiB After Width: | Height: | Size: 11 KiB |
|
Before Width: | Height: | Size: 12 KiB After Width: | Height: | Size: 12 KiB |
@ -37,6 +37,7 @@ function getGeomFromLineType(linetype::Symbol)
|
|||||||
linetype == :step && return Gadfly.Geom.step
|
linetype == :step && return Gadfly.Geom.step
|
||||||
linetype == :hist && return Gadfly.Geom.hist
|
linetype == :hist && return Gadfly.Geom.hist
|
||||||
linetype == :none && return Gadfly.Geom.point # change this? are we usually pairing no line with scatterplots?
|
linetype == :none && return Gadfly.Geom.point # change this? are we usually pairing no line with scatterplots?
|
||||||
|
linetype == :sticks && return Gadfly.Geom.bar
|
||||||
error("linetype $linetype not currently supported with Gadfly")
|
error("linetype $linetype not currently supported with Gadfly")
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
@ -7,6 +7,9 @@ function adjustQwtKeywords(; kw...)
|
|||||||
d = Dict(kw)
|
d = Dict(kw)
|
||||||
if d[:linetype] == :hexbin
|
if d[:linetype] == :hexbin
|
||||||
d[:linetype] = :heatmap
|
d[:linetype] = :heatmap
|
||||||
|
elseif d[:linetype] == :dots
|
||||||
|
d[:linetype] = :none
|
||||||
|
d[:marker] = :hexagon
|
||||||
end
|
end
|
||||||
d[:heatmap_n] = d[:nbins]
|
d[:heatmap_n] = d[:nbins]
|
||||||
d
|
d
|
||||||
|
|||||||