Skip to content

Commit

Permalink
Merge pull request #51 from Marco-Congedo/dev
Browse files Browse the repository at this point in the history
v 0.1.10
  • Loading branch information
Marco-Congedo authored Mar 18, 2020
2 parents 37bda0d + 00c253c commit 5bc7e2e
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 8 deletions.
2 changes: 1 addition & 1 deletion Project.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name = "Diagonalizations"
uuid = "9cd687f3-b62d-43f3-8fd3-ffcd9e581047"
authors = ["Marco-Congedo <marco.congedo@gmail.com>"]
version = "0.1.9"
version = "0.1.10"

[deps]
CovarianceEstimation = "587fd27a-f159-11e8-2dae-1979310e6154"
Expand Down
2 changes: 1 addition & 1 deletion docs/Project.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
authors = ["Marco-Congedo <marco.congedo@gmail.com>"]
version = "0.1.9"
version = "0.1.10"

[deps]
Documenter = "e30172f5-a6a5-5a46-863b-614d45cd2de4"
Expand Down
10 changes: 4 additions & 6 deletions src/cca.jl
Original file line number Diff line number Diff line change
Expand Up @@ -513,17 +513,15 @@ function cca(Cx :: SorH, Cy :: SorH, Cxy :: Mat;
size(Cy, 2)==size(Cxy, 2) || throw(ArgumentError(📌*", cca function: Matrices `Cy` and `Cxy` must have the same number of rows"))

args=("Canonical Correlation Analysis", false)
kwargs=(eVarMeth=eVarMeth, simple=true);
e=eVar

x=whitening(Cx; eVar=eVarCx, kwargs...)
y=whitening(Cy; eVar=eVarCy, kwargs...)
m=mca(x.F'*Cxy*y.F; eVar=e, kwargs...)
x=whitening(Cx; eVar=eVarCx, eVarMeth=eVarMeth)
y=whitening(Cy; eVar=eVarCy, eVarMeth=eVarMeth)
m=mca(x.F'*Cxy*y.F; eVar=eVar, eVarMeth=eVarMeth)

if simple
LF([x.F*m.F[1], y.F*m.F[2]], [m.iF[1]*x.iF, m.iF[2]*y.iF], m.D, ○, ○, ○, args...)
else
e, D, U, V, p, arev=_ssdxy!(e, diag(m.D), m.F[1], m.F[2], _minDim(Cxy), eVarMeth)
e, D, U, V, p, arev=_ssdxy!(eVar, diag(m.D), m.F[1], m.F[2], _minDim(Cxy), eVarMeth)
LF([x.F*U, y.F*V], [U'*x.iF, V'*y.iF], D, e, diag(m.D), arev, args...)
end
end
Expand Down

0 comments on commit 5bc7e2e

Please sign in to comment.