misc
This commit is contained in:
parent
04c6726b76
commit
dfc7658426
File diff suppressed because one or more lines are too long
@ -249,13 +249,13 @@ end
|
|||||||
function buildSubplotObject!(subplt::Subplot{QwtPackage}, isbefore::Bool)
|
function buildSubplotObject!(subplt::Subplot{QwtPackage}, isbefore::Bool)
|
||||||
isbefore && return false
|
isbefore && return false
|
||||||
i = 0
|
i = 0
|
||||||
rows = []
|
rows = Any[]
|
||||||
row = []
|
row = Any[]
|
||||||
for (i,(r,c)) in enumerate(subplt.layout)
|
for (i,(r,c)) in enumerate(subplt.layout)
|
||||||
push!(row, subplt.plts[i].o)
|
push!(row, subplt.plts[i].o)
|
||||||
if c == ncols(subplt.layout, r)
|
if c == ncols(subplt.layout, r)
|
||||||
push!(rows, Qwt.hsplitter(row...))
|
push!(rows, Qwt.hsplitter(row...))
|
||||||
row = []
|
row = Any[]
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
# for rowcnt in subplt.layout.rowcounts
|
# for rowcnt in subplt.layout.rowcounts
|
||||||
|
|||||||
@ -79,16 +79,16 @@ function corrplot{T<:Real,S<:Real}(mat::AMat{T}, corrmat::AMat{S};
|
|||||||
if i==j
|
if i==j
|
||||||
# histogram on diagonal
|
# histogram on diagonal
|
||||||
histogram!(plt, mat[:,i], c=:black, leg=false)
|
histogram!(plt, mat[:,i], c=:black, leg=false)
|
||||||
i > 1 && plot!(yticks = :none)
|
i > 1 && plot!(plt, yticks = :none)
|
||||||
else
|
else
|
||||||
# scatter plots off-diagonal, color determined by correlation
|
# scatter plots off-diagonal, color determined by correlation
|
||||||
c = RGBA(RGB(getColorZ(cgrad, corrmat[i,j])), 0.3)
|
c = RGBA(RGB(getColorZ(cgrad, corrmat[i,j])), 0.3)
|
||||||
scatter!(plt, mat[:,j], mat[:,i], w=0, ms=3, c=c, leg=false)
|
scatter!(plt, mat[:,j], mat[:,i], w=1, ms=3, c=c, leg=false)
|
||||||
end
|
end
|
||||||
|
|
||||||
if labels != nothing && length(labels) >= m
|
if labels != nothing && length(labels) >= m
|
||||||
i == m && xlabel!(string(labels[j]))
|
i == m && xlabel!(plt, string(labels[j]))
|
||||||
j == 1 && ylabel!(string(labels[i]))
|
j == 1 && ylabel!(plt, string(labels[i]))
|
||||||
end
|
end
|
||||||
|
|
||||||
# # replace the plt
|
# # replace the plt
|
||||||
|
|||||||
@ -122,6 +122,8 @@ function expandLimits!(lims, x)
|
|||||||
e1, e2 = extrema(x)
|
e1, e2 = extrema(x)
|
||||||
lims[1] = min(lims[1], e1)
|
lims[1] = min(lims[1], e1)
|
||||||
lims[2] = max(lims[2], e2)
|
lims[2] = max(lims[2], e2)
|
||||||
|
catch err
|
||||||
|
warn(err)
|
||||||
end
|
end
|
||||||
nothing
|
nothing
|
||||||
end
|
end
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user