Gerber Information Quality Covariance
PortfolioOptimisers.BaseGerberIQCovariance Type
abstract type BaseGerberIQCovariance <: BaseGerberCovarianceAbstract supertype for all Gerber Information Quality covariance estimators in PortfolioOptimisers.jl.
All concrete and/or abstract types implementing Gerber Information Quality covariance estimation algorithms should be subtypes of BaseGerberIQCovariance.
Related
References
- [7] Gerber, Sander and Smyth, William and Markowitz, Harry and Miao, Yinsen and Ernst, Philip and Sargen, Paul, Squeezing Financial Noise: A Novel Approach to Covariance Matrix Estimation (December 01, 2025). Available at SSRN: https://ssrn.com/abstract=4986939 or http://dx.doi.org/10.2139/ssrn.4986939
PortfolioOptimisers.GerberIQCovarianceAlgorithm Type
abstract type GerberIQCovarianceAlgorithm <: AbstractMomentAlgorithmAbstract supertype for all Gerber Information Quality covariance estimation algorithms in PortfolioOptimisers.jl.
All concrete and/or abstract types implementing Gerber Information Quality covariance estimation algorithms should be subtypes of GerberIQCovarianceAlgorithm.
Related
References
- [7] Gerber, Sander and Smyth, William and Markowitz, Harry and Miao, Yinsen and Ernst, Philip and Sargen, Paul, Squeezing Financial Noise: A Novel Approach to Covariance Matrix Estimation (December 01, 2025). Available at SSRN: https://ssrn.com/abstract=4986939 or http://dx.doi.org/10.2139/ssrn.4986939
PortfolioOptimisers.clamp_gerber_iq_n Function
clamp_gerber_iq_n(
kind::GerberIQCovarianceAlgorithm,
args...
) -> PartialGerberIQ{<:Number, <:Number, <:Number, <:Number, <:Number, <:Number, <:Number, <:Number, <:Number, <:Number, <:Number, <:Number, <:Number, <:Number}No-op for Gerber Information Quality covariance estimation algorithms that do not need their noise suppression parameters clamped.
Returns
kind: The inputkindinstance.
Related
sourceclamp_gerber_iq_n(
alg::PartialGerberIQ,
_::Gerber2
) -> PartialGerberIQ{<:Number, <:Number, <:Number, <:Number, <:Number, <:Number, <:Number, <:Number, <:Number, <:Number, <:Number, <:Number, <:Number, <:Number}Clamps the values of the off-diagonal elements of the covariance matrix for the PartialGerberIQ template when using the Gerber2 algorithm to ensure positive definiteness.
Arguments
alg: Instance ofPartialGerberIQ.::Gerber2: Instance ofGerber2.
Details
Clamps off-diagonal elements to be at most equal to the geometric mean of its adjacent diagonal elements.
This affects
n7andn8.
Related
References
- [7] Gerber, Sander and Smyth, William and Markowitz, Harry and Miao, Yinsen and Ernst, Philip and Sargen, Paul, Squeezing Financial Noise: A Novel Approach to Covariance Matrix Estimation (December 01, 2025). Available at SSRN: https://ssrn.com/abstract=4986939 or http://dx.doi.org/10.2139/ssrn.4986939
clamp_gerber_iq_n(
alg::FullGerberIQ,
_::Gerber2
) -> FullGerberIQ{_A, _B, _C, _D, <:Number, <:Number, <:Number, <:Number, <:Number, <:Number, <:Number, <:Number, <:Number, <:Number, <:Number, <:Number, <:Number, <:Number, <:Number, <:Number, <:Number, <:Number, <:Number, <:Number, <:Number} where {_A, _B, _C, _D}Clamps the values of the off-diagonal elements of the covariance matrix for the FullGerberIQ template when using the Gerber2 algorithm to ensure positive definiteness.
Arguments
alg: Instance ofFullGerberIQ.::Gerber2: Instance ofGerber2.
Details
Clamps off-diagonal elements to be at most equal to the geometric mean of its adjacent diagonal elements.
This affects
n7,n8,n14, andn17.
Related
References
- [7] Gerber, Sander and Smyth, William and Markowitz, Harry and Miao, Yinsen and Ernst, Philip and Sargen, Paul, Squeezing Financial Noise: A Novel Approach to Covariance Matrix Estimation (December 01, 2025). Available at SSRN: https://ssrn.com/abstract=4986939 or http://dx.doi.org/10.2139/ssrn.4986939
PortfolioOptimisers.GerberIQEpsEstimator Type
abstract type GerberIQEpsEstimator <: AbstractEstimatorAbstract supertype for all temporal lookback and delay Gerber Information Quality parameter estimators in PortfolioOptimisers.jl.
All concrete and/or abstract types implementing Gerber Information Quality parameter estimators should be subtypes of GerberIQEpsEstimator.
Related
References
- [7] Gerber, Sander and Smyth, William and Markowitz, Harry and Miao, Yinsen and Ernst, Philip and Sargen, Paul, Squeezing Financial Noise: A Novel Approach to Covariance Matrix Estimation (December 01, 2025). Available at SSRN: https://ssrn.com/abstract=4986939 or http://dx.doi.org/10.2139/ssrn.4986939
PortfolioOptimisers.GerberIQEps Type
const GerberIQEps = Union{<:Number, Function, <:GerberIQEpsEstimator}A type alias for the union of Number, Function, and GerberIQEpsEstimator used for Gerber Information Quality lookback and delay parameter definitions.
Related
References
- [7] Gerber, Sander and Smyth, William and Markowitz, Harry and Miao, Yinsen and Ernst, Philip and Sargen, Paul, Squeezing Financial Noise: A Novel Approach to Covariance Matrix Estimation (December 01, 2025). Available at SSRN: https://ssrn.com/abstract=4986939 or http://dx.doi.org/10.2139/ssrn.4986939
PortfolioOptimisers.gerber_iq_eps Function
gerber_iq_eps(e::Number, ::MatNum) -> Number
gerber_iq_eps(e::Function, X::MatNum) -> Number
gerber_iq_eps(e::Option{<:GerberIQEpsEstimator}, X::MatNum) -> NumberComputes or returns the Gerber Information Quality delay parameter e, potentially using X as an input.
Arguments
e: The delay parameter estimator, function or value for use in the decay equation.::Number: Use the number as-is.::Function: A function which takes the data matrixXas an argument and returns aNumber.::Option{<:GerberIQEpsEstimator}: Fallback returninground(Int, T - T / N), whereTandNare the number of rows and columns ofXrespectively.
X: Data matrixobservations × featuresif thedimskeyword does not exist ordims = 1,features × observationswhendims = 2.
Returns
tau::Number: The lookback parameter for use in the decay equation.
References
- [7] Gerber, Sander and Smyth, William and Markowitz, Harry and Miao, Yinsen and Ernst, Philip and Sargen, Paul, Squeezing Financial Noise: A Novel Approach to Covariance Matrix Estimation (December 01, 2025). Available at SSRN: https://ssrn.com/abstract=4986939 or http://dx.doi.org/10.2139/ssrn.4986939
PortfolioOptimisers.GerberIQGammaEstimator Type
abstract type GerberIQGammaEstimator <: AbstractEstimatorAbstract supertype for Gerber IQ estimators for tuning the strength of the lookback decay.
All concrete and/or abstract types implementing Gerber Information Quality parameter estimators should be subtypes of GerberIQGammaEstimator.
Related
References
- [7] Gerber, Sander and Smyth, William and Markowitz, Harry and Miao, Yinsen and Ernst, Philip and Sargen, Paul, Squeezing Financial Noise: A Novel Approach to Covariance Matrix Estimation (December 01, 2025). Available at SSRN: https://ssrn.com/abstract=4986939 or http://dx.doi.org/10.2139/ssrn.4986939
PortfolioOptimisers.GerberIQGamma Type
const GerberIQGamma = Union{<:Number, Function, <:GerberIQGammaEstimator}A type alias for the union of Number, Function, and GerberIQGammaEstimator used for Gerber Information Quality temporal decay parameter definitions.
Related
References
- [7] Gerber, Sander and Smyth, William and Markowitz, Harry and Miao, Yinsen and Ernst, Philip and Sargen, Paul, Squeezing Financial Noise: A Novel Approach to Covariance Matrix Estimation (December 01, 2025). Available at SSRN: https://ssrn.com/abstract=4986939 or http://dx.doi.org/10.2139/ssrn.4986939
PortfolioOptimisers.gerber_iq_gamma Function
gerber_iq_gamma(y::Number, ::MatNum) -> Number
gerber_iq_gamma(y::Function, X::MatNum) -> Number
gerber_iq_gamma(y::Option{<:GerberIQGammaEstimator}, X::MatNum) -> NumberComputes or returns the Gerber Information Quality decay strength parameter y, potentially using X as an input.
Arguments
y: The decay strength parameter estimator, function or value for use in the decay equation.::Number: Use the number as-is.::Function: A function which takes the data matrixXas an argument and returns aNumber.::Option{<:GerberIQGammaEstimator}: Fallback returninglog(2) / size(X, 2).
X: Data matrixobservations × featuresif thedimskeyword does not exist ordims = 1,features × observationswhendims = 2.
Returns
gamma::Number: The decay strength parameter for use in the decay equation.
References
- [7] Gerber, Sander and Smyth, William and Markowitz, Harry and Miao, Yinsen and Ernst, Philip and Sargen, Paul, Squeezing Financial Noise: A Novel Approach to Covariance Matrix Estimation (December 01, 2025). Available at SSRN: https://ssrn.com/abstract=4986939 or http://dx.doi.org/10.2139/ssrn.4986939
PortfolioOptimisers.GerberIQScalerEstimator Type
abstract type GerberIQScalerEstimator <: AbstractEstimatorAbstract supertype for Gerber IQ estimators for scaling the threshold parameters for defining significant co-movements.
All concrete and/or abstract types implementing threshold scalers for Gerber Information Quality parameter estimators should be subtypes of GerberIQScalerEstimator.
Related
References
- [7] Gerber, Sander and Smyth, William and Markowitz, Harry and Miao, Yinsen and Ernst, Philip and Sargen, Paul, Squeezing Financial Noise: A Novel Approach to Covariance Matrix Estimation (December 01, 2025). Available at SSRN: https://ssrn.com/abstract=4986939 or http://dx.doi.org/10.2139/ssrn.4986939
PortfolioOptimisers.GerberIQScaler Type
const GerberIQScaler = Union{Function, <:GerberIQScalerEstimator}A type alias for the union of Function, and GerberIQScalerEstimator used for scaling the threshold parameters for defining significant co-movements in Gerber Information Quality.
Related
References
- [7] Gerber, Sander and Smyth, William and Markowitz, Harry and Miao, Yinsen and Ernst, Philip and Sargen, Paul, Squeezing Financial Noise: A Novel Approach to Covariance Matrix Estimation (December 01, 2025). Available at SSRN: https://ssrn.com/abstract=4986939 or http://dx.doi.org/10.2139/ssrn.4986939
PortfolioOptimisers.AssetVolatilityGerberIQScaler Type
struct AssetVolatilityGerberIQScaler <: GerberIQScalerEstimatorScales the threshold parameters using the individual asset volatilities.
Related
References
- [7] Gerber, Sander and Smyth, William and Markowitz, Harry and Miao, Yinsen and Ernst, Philip and Sargen, Paul, Squeezing Financial Noise: A Novel Approach to Covariance Matrix Estimation (December 01, 2025). Available at SSRN: https://ssrn.com/abstract=4986939 or http://dx.doi.org/10.2139/ssrn.4986939
PortfolioOptimisers.gerber_iq_scaling Function
gerber_iq_scaling(sca::AssetVolatilityGerberIQScaler, sdi::Number, sdj::Number) -> (Number, Number)
gerber_iq_scaling(sca::Function, sdi::Number, sdj::Number) -> (Number, Number)
gerber_iq_scaling(sca::Option{<:GerberIQScalerEstimator}, sdi::Number, sdj::Number) -> (Number, Number)Computes or returns the threshold scaling parameters for defining significant co-movements in Gerber Information Quality.
Arguments
sca: The scaling estimator to use.::AssetVolatilityGerberIQScaler: Returns the inputsdiandsdjas-is. This lets each asset scale according to its own volatility.::Option{<:GerberIQScalerEstimator}: Fallback returning the mean ofsdiandsdjtwice so each asset is scaled according to the mean of the two asset volatilities. Overloading this with a customGerberIQScalerEstimatorallows for custom scaling behavior.::Function: Custom scaling function that takessdiandsdjas arguments and returns the scaled values.
Returns
scai::Number: The scaled value forsdi.scaj::Number: The scaled value forsdj.
References
- [7] Gerber, Sander and Smyth, William and Markowitz, Harry and Miao, Yinsen and Ernst, Philip and Sargen, Paul, Squeezing Financial Noise: A Novel Approach to Covariance Matrix Estimation (December 01, 2025). Available at SSRN: https://ssrn.com/abstract=4986939 or http://dx.doi.org/10.2139/ssrn.4986939
PortfolioOptimisers.GerberIQDecayEstimator Type
abstract type GerberIQDecayEstimator <: AbstractEstimatorAbstract supertype for Gerber IQ estimators for scaling the threshold parameters for defining significant co-movements.
All concrete and/or abstract types implementing threshold scalers for Gerber Information Quality parameter estimators should be subtypes of GerberIQDecayEstimator.
Interfaces
In order to implement a new Gerber IQ decay estimator which will work seamlessly with the library, subtype GerberIQDecayEstimator with all necessary parameters as part of the struct, and implement the following methods:
Regenerate Decay
PortfolioOptimisers.regenerate_decay(decay::GerberIQDecayEstimator, X::AbstractMatrix) -> GerberIQDecayEstimator: Fallback for automatically computing the decay parameters based on the input dataX.
Arguments
decay: The decay estimator to regenerate.X: Data matrixobservations × featuresif thedimskeyword does not exist ordims = 1,features × observationswhendims = 2.
Returns
decay::GerberIQDecayEstimator: A new concrete instance of the subtype ofGerberIQDecayEstimatorwith the decay parameters generated from the input dataX.
Functor
(decay::GerberIQDecayEstimator)(T::Number, k::Number) -> Number: Evaluate the decay estimator for observationkout ofT.
Arguments
T::Number: The total number of observations.k::Number: The current observation index.
Returns
d::Number: The decay value for observationkout ofT.
Examples
We can create a dummy Gerber IQ decay estimator as follows:
julia> struct GaussianDecay{T} <: PortfolioOptimisers.GerberIQDecayEstimator
a::T
function GaussianDecay(a::Union{Nothing, <:Number})
if isa(a, Number)
@assert(a >= 0)
end
return new{typeof(a)}(a)
end
end
julia> function GaussianDecay(; a::Union{Nothing, <:Number} = nothing)
return GaussianDecay(a)
end
GaussianDecay
julia> function PortfolioOptimisers.regenerate_decay(decay::GaussianDecay{<:Number},
::AbstractMatrix)
return decay
end
julia> function PortfolioOptimisers.regenerate_decay(decay::GaussianDecay{Nothing},
X::AbstractMatrix)
T = size(X, 1)
return GaussianDecay(; a = inv(log(T)))
end
julia> function (decay::GaussianDecay)(T::Number, k::Number)
m = T - k + 1
return exp(-m^2 / (2 * decay.a^2))
end
julia> cor(GerberIQCovariance(; decay = GaussianDecay()), [1.0 2.0; 0.3 0.7; 0.5 1.1])
2×2 Matrix{Float64}:
1.0 1.0
1.0 1.0
julia> cov(GerberIQCovariance(; decay = GaussianDecay()), [1.0 2.0; 0.3 0.7; 0.5 1.1])
2×2 Matrix{Float64}:
0.13 0.240069
0.240069 0.443333Related
References
- [7] Gerber, Sander and Smyth, William and Markowitz, Harry and Miao, Yinsen and Ernst, Philip and Sargen, Paul, Squeezing Financial Noise: A Novel Approach to Covariance Matrix Estimation (December 01, 2025). Available at SSRN: https://ssrn.com/abstract=4986939 or http://dx.doi.org/10.2139/ssrn.4986939
PortfolioOptimisers.ExpGerberIQDecay Type
struct ExpGerberIQDecay{__T_e, __T_y} <: GerberIQDecayEstimatorA concrete type for exponential Gerber IQ temporal decay.
Fields
e: Waiting period before the decay starts.y: Decay rate parameter.
Constructors
ExpGerberIQDecay(e::Option{<:GerberIQEps} = nothing,
y::Option{<:GerberIQGamma} = nothing)Keywords correspond to the struct's fields.
Functors
(decay::ExpGerberIQDecay)(T::Number, k::Number) -> NumberImplements the exponential decay for Gerber IQ covariance.
!!! Warning
The functor is not meant to be called directly unless all parameters are numeric. Otherwise, call [`regenerate_decay`](@ref) first.Where:
: Is the number of observations. : Is the current index. : Parameter in the instance of ExpGerberIQDecay.: Parameter in the instance of ExpGerberIQDecay.: Is the decay factor.
Arguments
T: Number of observations.k: Current time index.
Returns
d: The decay factor.
Examples
julia> ExpGerberIQDecay()
ExpGerberIQDecay
e ┼ nothing
y ┴ nothingRelated
References
- [7] Gerber, Sander and Smyth, William and Markowitz, Harry and Miao, Yinsen and Ernst, Philip and Sargen, Paul, Squeezing Financial Noise: A Novel Approach to Covariance Matrix Estimation (December 01, 2025). Available at SSRN: https://ssrn.com/abstract=4986939 or http://dx.doi.org/10.2139/ssrn.4986939
PortfolioOptimisers.regenerate_decay Function
regenerate_decay(decay::ExpGerberIQDecay, X::AbstractMatrix) -> ExpGerberIQDecay
regenerate_decay(decay::GerberIQDecayEstimator, X::AbstractMatrix) -> ExpGerberIQDecayAutomatically sets the decay parameters based on the input data X.
Arguments
decay: The decay estimator to regenerate.::ExpGerberIQDecay: If both parameters are numeric, returns the input, otherwise returns a newExpGerberIQDecaywith the regenerated parameters.::GerberIQDecayEstimator: Fallback for automatically setting the decay parameterse, andybased on the input dataX, usinggerber_iq_epsandgerber_iq_gammawithnothingas the first input. Custom subtypes ofGerberIQDecayEstimatorshould implement this method, else they default to the fallback.
X: Data matrixobservations × featuresif thedimskeyword does not exist ordims = 1,features × observationswhendims = 2.
Returns
decay::ExpGerberIQDecay: With parameters based onX.
Details
Calls
gerber_iq_epsto set ande.Calls
gerber_iq_gammato sety.Returns a new
ExpGerberIQDecaywith the regenerated parameters.
Related
References
- [7] Gerber, Sander and Smyth, William and Markowitz, Harry and Miao, Yinsen and Ernst, Philip and Sargen, Paul, Squeezing Financial Noise: A Novel Approach to Covariance Matrix Estimation (December 01, 2025). Available at SSRN: https://ssrn.com/abstract=4986939 or http://dx.doi.org/10.2139/ssrn.4986939
PortfolioOptimisers.BasicGerberIQ Type
struct BasicGerberIQ{__T_d, __T_n} <: GerberIQCovarianceAlgorithmImplements the basic Gerber IQ covariance template. Divides the comovement data into regions and applies the co-movement compression to co-movements falling within each region. Co-movements within the dashed regions may or may not be included depending on the GerberIQ algorithm used. Co-movements within the central region are always ignored.
Fields
d: Significance threshold parameter.n: Comovement compression parameter.
Constructors
BasicGerberIQ(; d::Number = 2.0, n::Number = 0.5)Keywords correspond to the struct's fields.
Validation
dis validated viaassert_nonempty_nonneg_finite_val.0 <= n <= 1.
Details
The diagram shows a visual representation of the regions defined by BasicGerberIQ. In this case c = 1 and d = 3.
The dashed lines indicate the limits of the areas where movements are considered small.
Only the
Gerber1algorithm takes these regions into account as part of the neutral count.The region where co-movements are considered insignificant in both axes (square around r0) are always ignored.
Single weight lines indicate zero delimiters.
The double weight lines indicate areas where movements are considered significant.
Co-movements within each region are weighed according to their labels.
4 ┬─────┰───────────┬─────┬─────┬───────────┰─────┐
┌──── │ 1 ┃ n^2 ╎ │ ╎ n^2 ┃ 1 │
d ─┤ 3 ┾━━━━━╋━━━━━━━━━━━┿━━━━━┿━━━━━┿━━━━━━━━━━━╋━━━━━┥
└──── │ ┃ ╎ │ ╎ ┃ │
2 ┤ n^2 ┃ n ╎ │ ╎ n ┃ n^2 │
│ ┃ ╎ │ ╎ ┃ │
┌──── 1 ┼╌╌╌╌╌╂╌╌╌╌╌╌╌╌╌╌╌┼╌╌╌╌╌┴╌╌╌╌╌┼╌╌╌╌╌╌╌╌╌╌╌╂╌╌╌╌╌┤
│ │ ┃ ╎ ╎ ┃ │
2c ─┤ r_j 0 ┼─────╂───────────┤ r0 ├───────────╂─────┤
│ │ ┃ ╎ ╎ ┃ │
└──── -1 ┼╌╌╌╌╌╂╌╌╌╌╌╌╌╌╌╌╌┼╌╌╌╌╌┬╌╌╌╌╌┼╌╌╌╌╌╌╌╌╌╌╌╂╌╌╌╌╌┤
│ ┃ ╎ │ ╎ ┃ │
-2 ┤ n^2 ┃ n ╎ │ ╎ n ┃ n^2 │
┌──── │ ┃ ╎ │ ╎ ┃ │
d ─┤ -3 ┾━━━━━╋━━━━━━━━━━━┿━━━━━┿━━━━━┿━━━━━━━━━━━╋━━━━━┥
└──── │ 1 ┃ n^2 ┊ │ ╎ n^2 ┃ 1 │
-4 ┼─────╀─────┬─────┼─────┼─────┼─────┬─────╀─────┤
-4 -3 -2 -1 0 1 2 3 4
r_i
│ │ │ │ │ │
└──┬──┘ └─────┬─────┘ └──┬──┘
d 2c dExamples
julia> BasicGerberIQ()
BasicGerberIQ
d ┼ Float64: 2.0
n ┴ Float64: 0.5Related
References
- [7] Gerber, Sander and Smyth, William and Markowitz, Harry and Miao, Yinsen and Ernst, Philip and Sargen, Paul, Squeezing Financial Noise: A Novel Approach to Covariance Matrix Estimation (December 01, 2025). Available at SSRN: https://ssrn.com/abstract=4986939 or http://dx.doi.org/10.2139/ssrn.4986939
PortfolioOptimisers.PartialGerberIQ Type
struct PartialGerberIQ{__T_dcp, __T_dcn, __T_ddp, __T_ddn, __T_n1, __T_n2, __T_n3, __T_n4, __T_n5, __T_n6, __T_n7, __T_n8, __T_n9, __T_n10} <: GerberIQCovarianceAlgorithmFields
dcp: Positive concordant movement threshold parameter.dcn: Negative concordant movement threshold parameter.ddp: Discordant movement threshold parameter, positive inr_i, negative inr_j.ddn: Discordant movement threshold parameter, negative inr_i, positive inr_j.n1: Noise suppression parameter for small positive concordant movements.n2: Noise suppression parameter for small negative concordant movements.n3: Noise suppression parameter for small discordant movements.n4: Noise suppression parameter for large positive concordant movements.n5: Noise suppression parameter for large negative concordant movements.n6: Noise suppression parameter for large discordant movements.n7: Noise suppression parameter for positive concordant movements where one axis has a large movement and the other is small.n8: Noise suppression parameter for negative concordant movements where one axis has a large movement and the other is small.n9: Noise suppression parameter for discordant movements where one axis has a large movement and the other is small for the region betweenddnand zero.n10: Noise suppression parameter for discordant movements where one axis has a large movement and the other is small for the region betweenddpand zero.
Constructors
PartialGerberIQ(; dcp::Number = 2.0, dcn::Number = dcp, ddp::Number = dcp,
ddn::Number = dcp, n1::Number = 0.5, n2::Number = n1,
n3::Number = n1, n4::Number = 1.0, n5::Number = n4,
n6::Number = n4, n7::Number = sqrt(n1 * n4),
n8::Number = sqrt(n2 * n5), n9::Number = sqrt(n3 * n6),
n10::Number = sqrt(n3 * n6))Keywords correspond to the struct's fields.
Validation
All
d**parameters are validated viaassert_nonempty_nonneg_finite_val.All
n**parameters must be0 <= n** <= 1.
Details
The diagram shows a visual representation of the regions defined by PartialGerberIQ. In this case c = 1, dcp = 2, ddn = 2, ddp = 3, and dcn = 3.
The dashed lines indicate the limits of the areas where movements are considered small.
Only the
Gerber1algorithm takes these regions into account as part of the neutral count.The region where co-movements are considered insignificant in both axes (square around r0) are always ignored.
Single weight lines indicate zero delimiters.
The double weight lines indicate areas where movements are considered significant.
Co-movements within each region are weighed according to their labels.
ddn dcp
┌──┴──┐ ┌──┴──┐
│ │ │ │
4 ┬───────────┰─────┬─────┬─────┬─────┰───────────┐
┌──── │ n6 ┃ n9 ╎ │ ╎ ┃ │
ddp ─┤ 3 ┾━━━━━━━━━━━╋━━━━━┿━━━━━┥ ╎ n7 ┃ n4 │
└──── │ ┃ ╎ │ ╎ ┃ │ ────┐
2 ┤ n10 ┃ n3 ╎ ┝━━━━━┿━━━━━╋━━━━━━━━━━━┥ ├─ dcp
│ ┃ ╎ │ ╎ n1 ┃ n7 │ ────┘
┌──── 1 ┼╌╌╌╌╌╌╌╌╌╌╌╂╌╌╌╌╌┼╌╌╌╌╌┴╌╌╌╌╌┼╌╌╌╌╌╂╌╌╌╌╌╌╌╌╌╌╌┤
│ │ ┃ ╎ ╎ ┃ │
2c ─┤ r_j 0 ┼─────┰─────┸─────┤ r0 ├─────┸─────┰─────┤
│ │ ┃ ╎ ╎ ┃ │
└──── -1 ┼╌╌╌╌╌╂╌╌╌╌╌╌╌╌╌╌╌┼╌╌╌╌╌┬╌╌╌╌╌┼╌╌╌╌╌╌╌╌╌╌╌╂╌╌╌╌╌┤
│ ┃ ╎ │ ╎ n3 ┃ n9 │ ────┐
-2 ┤ n8 ┃ n2 ╎ ┝━━━━━┿━━━━━━━━━━━╋━━━━━┥ ├─ ddn
┌──── │ ┃ ╎ │ ╎ ┃ │ ────┘
dcn ─┤ -3 ┾━━━━━╋━━━━━━━━━━━┿━━━━━┥ ╎ n10 ┃ n6 │
└──── │ n5 ┃ n8 ╎ │ ╎ ┃ │
-4 ┼─────╀─────┬─────┼─────┼─────┼─────┬─────╀─────┤
-4 -3 -2 -1 0 1 2 3 4
r_i
│ │ │ │ │ │
└──┬──┘ └─────┬─────┘ └──┬──┘
dcn 2c ddpExamples
julia> PartialGerberIQ()
PartialGerberIQ
dcp ┼ Float64: 2.0
dcn ┼ Float64: 2.0
ddp ┼ Float64: 2.0
ddn ┼ Float64: 2.0
n1 ┼ Float64: 0.5
n2 ┼ Float64: 0.5
n3 ┼ Float64: 0.5
n4 ┼ Float64: 1.0
n5 ┼ Float64: 1.0
n6 ┼ Float64: 1.0
n7 ┼ Float64: 0.7071067811865476
n8 ┼ Float64: 0.7071067811865476
n9 ┼ Float64: 0.7071067811865476
n10 ┴ Float64: 0.7071067811865476Related
References
- [7] Gerber, Sander and Smyth, William and Markowitz, Harry and Miao, Yinsen and Ernst, Philip and Sargen, Paul, Squeezing Financial Noise: A Novel Approach to Covariance Matrix Estimation (December 01, 2025). Available at SSRN: https://ssrn.com/abstract=4986939 or http://dx.doi.org/10.2139/ssrn.4986939
PortfolioOptimisers.FullGerberIQ Type
struct FullGerberIQ{__T_dp1, __T_dp2, __T_dn1, __T_dn2, __T_n1, __T_n2, __T_n3, __T_n4, __T_n5, __T_n6, __T_n7, __T_n8, __T_n9, __T_n10, __T_n11, __T_n12, __T_n13, __T_n14, __T_n15, __T_n16, __T_n17, __T_n18, __T_n19, __T_n20, __T_n21} <: GerberIQCovarianceAlgorithmFields
dp1: Threshold for larger positive co-movements.dp2: Threshold for smaller positive co-movements.dn1: Threshold for larger negative co-movements.dn2: Threshold for smaller negative co-movements.n1: Threshold for small positive concordant co-movements.n2: Threshold for small negative concordant co-movements.n3: Threshold for small discordant co-movements.n4: Threshold for moderate positive concordant co-movements.n5: Threshold for moderate negative concordant co-movements.n6: Threshold for moderate discordant co-movements.n7: Threshold for small and moderate positive concordant co-movements.n8: Threshold for small and moderate negative concordant co-movements.n9: Threshold for small and moderate discordant co-movements.n10: Threshold for moderate and small discordant co-movements.n11: Threshold for large positive concordant co-movements.n12: Threshold for large negative concordant co-movements.n13: Threshold for large discordant co-movements.n14: Threshold for moderate and large positive concordant co-movements.n15: Threshold for small and large positive concordant co-movements.n16: Threshold for small and large negative concordant co-movements.n17: Threshold for moderate and large positive concordant co-movements.n18: Threshold for small and large discordant co-movements.n19: Threshold for moderate and large discordant co-movements.n20: Threshold for large and moderate discordant co-movements.n21: Threshold for large and small discordant co-movements.
Constructors
FullGerberIQ(; dp1::Number = 2.0, dp2::Number = dp1, dn1::Number = dp1,
dn2::Number = dp1, n1::Number = 0.5, n2::Number = n1, n3::Number = n1,
n4::Number = 0.75, n5::Number = n4, n6::Number = n4,
n7::Number = sqrt(n1 * n4), n8::Number = sqrt(n2 * n5),
n9::Number = sqrt(n3 * n6), n10::Number = sqrt(n3 * n6),
n11::Number = 1.0, n12::Number = n11, n13::Number = n11,
n14::Number = sqrt(n4 * n11), n15::Number = sqrt(n7 * n14),
n17::Number = sqrt(n5 * n12), n16::Number = sqrt(n8 * n17),
n19::Number = sqrt(n6 * n13), n18::Number = sqrt(n9 * n19),
n20::Number = sqrt(n6 * n13), n21::Number = sqrt(n10 * n20))Keywords correspond to the struct's fields.
Validation
All
d**parameters are validated viaassert_nonempty_nonneg_finite_val.All
n**parameters must be0 <= n** <= 1.
Details
The diagram shows a visual representation of the regions defined by PartialGerberIQ. In this case c = 1, dp2 = 2, dn2 = 2, dp1 = 3, and dn1 = 3. In this version, the limits are allowed to cross over the zero line. Thus, the constructor ensures dp1 >= dp2 and dn1 >= dn2 by swapping values if necessary to ensure consistency.
The dashed lines indicate the limits of the areas where movements are considered small.
Only the
Gerber1algorithm takes these regions into account as part of the neutral count.The region where co-movements are considered insignificant in both axes (square around r0) are always ignored.
Single weight lines indicate zero delimiters.
The double weight lines indicate areas where movements are considered significant.
Co-movements within each region are weighed according to their labels.
dn2 dp2
┌──┴──┐ ┌──┴──┐
│ │ │ │
4 ┬─────┰─────┰─────┬─────┬─────┬─────┰─────┰─────┐
┌──── │ n13 ┃ n19 ┃ n18 ╎ │ ╎ n15 ┃ n14 ┃ n11 │
dp1 ─┤ 3 ┾━━━━━╋━━━━━╋━━━━━┿━━━━━┿━━━━━┿━━━━━╋━━━━━╋━━━━━┥
└──── │ n20 ┃ n6 ┃ n9 ╎ │ ╎ n7 ┃ n4 ┃ n14 │ ────┐
2 ┾━━━━━╋━━━━━╋━━━━━┿━━━━━┿━━━━━┿━━━━━╋━━━━━╋━━━━━┥ ├─ dp2
│ n21 ┃ n10 ┃ n3 ╎ │ ╎ n1 ┃ n7 ┃ n15 │ ────┘
┌──── 1 ┼╌╌╌╌╌╂╌╌╌╌╌╂╌╌╌╌╌┼╌╌╌╌╌┴╌╌╌╌╌┼╌╌╌╌╌╂╌╌╌╌╌╂╌╌╌╌╌┤
│ │ ┃ ┃ ╎ ╎ ┃ ┃ │
2c ─┤ r_j 0 ┼─────╂─────╂─────┤ r0 ├─────╂─────╂─────┤
│ │ ┃ ┃ ╎ ╎ ┃ ┃ │
└──── -1 ┼╌╌╌╌╌╂╌╌╌╌╌╂╌╌╌╌╌┼╌╌╌╌╌┬╌╌╌╌╌┼╌╌╌╌╌╂╌╌╌╌╌╂╌╌╌╌╌┤
│ n16 ┃ n8 ┃ n2 ╎ │ ╎ n3 ┃ n9 ┃ n18 │ ────┐
-2 ┾━━━━━╋━━━━━╋━━━━━┿━━━━━┿━━━━━┿━━━━━╋━━━━━╋━━━━━┥ ├─ dn2
┌──── │ n17 ┃ n5 ┃ n8 ╎ │ ╎ n10 ┃ n6 ┃ n19 │ ────┘
dn1 ─┤ -3 ┾━━━━━╋━━━━━╋━━━━━┿━━━━━┿━━━━━┿━━━━━╋━━━━━╋━━━━━┥
└──── │ n12 ┃ n17 ┃ n16 ╎ │ ╎ n21 ┃ n20 ┃ n13 │
-4 ┼─────╀─────╀─────┼─────┼─────┼─────╀─────╀─────┤
-4 -3 -2 -1 0 1 2 3 4
r_i
│ │ │ │ │ │
└──┬──┘ └─────┬─────┘ └──┬──┘
dn1 2c dp1Examples
julia> FullGerberIQ()
FullGerberIQ
dp1 ┼ Float64: 2.0
dp2 ┼ Float64: 2.0
dn1 ┼ Float64: 2.0
dn2 ┼ Float64: 2.0
n1 ┼ Float64: 0.5
n2 ┼ Float64: 0.5
n3 ┼ Float64: 0.5
n4 ┼ Float64: 0.75
n5 ┼ Float64: 0.75
n6 ┼ Float64: 0.75
n7 ┼ Float64: 0.6123724356957945
n8 ┼ Float64: 0.6123724356957945
n9 ┼ Float64: 0.6123724356957945
n10 ┼ Float64: 0.6123724356957945
n11 ┼ Float64: 1.0
n12 ┼ Float64: 1.0
n13 ┼ Float64: 1.0
n14 ┼ Float64: 0.8660254037844386
n15 ┼ Float64: 0.7282376575609851
n16 ┼ Float64: 0.7282376575609851
n17 ┼ Float64: 0.8660254037844386
n18 ┼ Float64: 0.7282376575609851
n19 ┼ Float64: 0.8660254037844386
n20 ┼ Float64: 0.8660254037844386
n21 ┴ Float64: 0.7282376575609851Related
References
- [7] Gerber, Sander and Smyth, William and Markowitz, Harry and Miao, Yinsen and Ernst, Philip and Sargen, Paul, Squeezing Financial Noise: A Novel Approach to Covariance Matrix Estimation (December 01, 2025). Available at SSRN: https://ssrn.com/abstract=4986939 or http://dx.doi.org/10.2139/ssrn.4986939
PortfolioOptimisers.gerber_iq_assert_c_d Function
gerber_iq_assert_c_d(c::Number, kind::BasicGerberIQ)Asserts that c <= kind.d, where c is the small movement threshold and d the significance threshold parameter of BasicGerberIQ.
Arguments
c: Small movement threshold.kind:BasicGerberIQinstance.
Related
References
- [7] Gerber, Sander and Smyth, William and Markowitz, Harry and Miao, Yinsen and Ernst, Philip and Sargen, Paul, Squeezing Financial Noise: A Novel Approach to Covariance Matrix Estimation (December 01, 2025). Available at SSRN: https://ssrn.com/abstract=4986939 or http://dx.doi.org/10.2139/ssrn.4986939
gerber_iq_assert_c_d(c::Number, kind::Union{<:PartialGerberIQ, <:FullGerberIQ}) -> NothingAsserts that all c <= kind.d**, where c is the small movement threshold and d** are the significance threshold parameters of PartialGerberIQ or FullGerberIQ.
Arguments
c: Small movement threshold.kind: Instance ofPartialGerberIQorFullGerberIQ.
Related
References
- [7] Gerber, Sander and Smyth, William and Markowitz, Harry and Miao, Yinsen and Ernst, Philip and Sargen, Paul, Squeezing Financial Noise: A Novel Approach to Covariance Matrix Estimation (December 01, 2025). Available at SSRN: https://ssrn.com/abstract=4986939 or http://dx.doi.org/10.2139/ssrn.4986939
PortfolioOptimisers.gerber_iq_weight Function
gerber_iq_weight(
_::Number,
_::Number,
axi::Number,
axj::Number,
sci::Number,
scj::Number,
kind::BasicGerberIQ
) -> AnyComputes the weight for a co-movement according to the region it falls into from the BasicGerberIQ template.
Arguments
xi: Return of asseti(unused).xj: Return of assetj(unused).axi: Absolute return of asseti.axj: Absolute return of assetj.sci: Scaling for movement of asseti.scj: Scaling for movement of assetj.kind: Instance ofBasicGerberIQ.
Returns
res::Number: Co-movement weight.
Related
References
- [7] Gerber, Sander and Smyth, William and Markowitz, Harry and Miao, Yinsen and Ernst, Philip and Sargen, Paul, Squeezing Financial Noise: A Novel Approach to Covariance Matrix Estimation (December 01, 2025). Available at SSRN: https://ssrn.com/abstract=4986939 or http://dx.doi.org/10.2139/ssrn.4986939
gerber_iq_weight(
xi::Number,
xj::Number,
axi::Number,
axj::Number,
sci::Number,
scj::Number,
kind::PartialGerberIQ
) -> AnyComputes the weight for a co-movement according to the region it falls into from the PartialGerberIQ template.
Arguments
xi: Return of asseti.xj: Return of assetj.axi: Absolute return of asseti(unused).axj: Absolute return of assetj(unused).sci: Scaling for movement of asseti.scj: Scaling for movement of assetj.kind: Instance ofPartialGerberIQ.
Returns
res::Number: Co-movement weight.
Related
References
- [7] Gerber, Sander and Smyth, William and Markowitz, Harry and Miao, Yinsen and Ernst, Philip and Sargen, Paul, Squeezing Financial Noise: A Novel Approach to Covariance Matrix Estimation (December 01, 2025). Available at SSRN: https://ssrn.com/abstract=4986939 or http://dx.doi.org/10.2139/ssrn.4986939
gerber_iq_weight(
xi::Number,
xj::Number,
axi::Number,
axj::Number,
sci::Number,
scj::Number,
kind::FullGerberIQ
) -> AnyComputes the weight for a co-movement according to the region it falls into from the FullGerberIQ template.
Arguments
xi: Return of asseti.xj: Return of assetj.axi: Absolute return of asseti(unused).axj: Absolute return of assetj(unused).sci: Scaling for movement of asseti.scj: Scaling for movement of assetj.kind: Instance ofFullGerberIQ.
Returns
res::Number: Co-movement weight.
Related
References
- [7] Gerber, Sander and Smyth, William and Markowitz, Harry and Miao, Yinsen and Ernst, Philip and Sargen, Paul, Squeezing Financial Noise: A Novel Approach to Covariance Matrix Estimation (December 01, 2025). Available at SSRN: https://ssrn.com/abstract=4986939 or http://dx.doi.org/10.2139/ssrn.4986939
PortfolioOptimisers.GerberIQCovariance Type
struct GerberIQCovariance{__T_ve, __T_me, __T_pdm, __T_c, __T_decay, __T_sc, __T_kind, __T_alg, __T_ex} <: BaseGerberIQCovarianceA flexible container type for configuring and applying Gerber Information Quality covariance estimators in PortfolioOptimisers.jl.
GerberIQCovariance encapsulates all components required for Gerber Information Quality based covariance or correlation estimation.
Fields
ve: Variance estimator.me: Expected returns estimator.pdm: Positive definite matrix estimator.c: Small co-movement threshold.decay: Temporal decay rate estimator for past observationsGerberIQDecayEstimator.sc: Threshold scaling factor estimator for co-movement thresholdsGerberIQScaler.kind: Gerber IQ covariance kind for squeezing co-movement noiseGerberIQCovarianceAlgorithm.alg: Gerber covariance algorithm.ex: Parallel execution strategy..
Constructors
GerberIQCovariance(; ve::StatsBase.CovarianceEstimator = SimpleVariance(),
me::AbstractExpectedReturnsEstimator = SimpleExpectedReturns(),
pdm::Option{<:Posdef} = Posdef(), c::Number = 0.5,
decay::GerberIQDecayEstimator = ExpGerberIQDecay(),
sc::Option{<:GerberIQScaler} = nothing,
kind::GerberIQCovarianceAlgorithm = BasicGerberIQ(),
alg::GerberCovarianceAlgorithm = Gerber1(),
ex::FLoops.Transducers.Executor = FLoops.Transducers.ThreadedEx())Keywords correspond to the struct's fields.
Validation
Related
References
- [7] Gerber, Sander and Smyth, William and Markowitz, Harry and Miao, Yinsen and Ernst, Philip and Sargen, Paul, Squeezing Financial Noise: A Novel Approach to Covariance Matrix Estimation (December 01, 2025). Available at SSRN: https://ssrn.com/abstract=4986939 or http://dx.doi.org/10.2139/ssrn.4986939
PortfolioOptimisers.factory Method
factory(
ce::GerberIQCovariance,
w::Union{DynamicAbstractWeights, AbstractWeights}
) -> GerberIQCovarianceReturn a new GerberIQCovariance estimator with the specified observation weights.
Arguments
ce: Covariance estimator.w: Optional observation weights vectorobservations × 1, or a concrete subtype ofDynamicAbstractWeights. Ifnothing, the computation is unweighted.
Returns
ce: New covariance estimator of the same type as the argument, with the new weights applied.
Details
Calls
factory(ce.alg, w)to update the algorithm (current algorithms do not use weights, this for future proofing).Calls
factory(ce.ve, w)to update the variance estimator.Calls
factory(ce.me, w)to update the expected returns estimator.Calls
factory(ce.decay, w)to update the decay estimator (current decay estimators do not use weights, this for future proofing).Preserves the other fields of the original estimator.
Examples
julia> ce = GerberIQCovariance()
GerberIQCovariance
ve ┼ SimpleVariance
│ me ┼ SimpleExpectedReturns
│ │ w ┴ nothing
│ w ┼ nothing
│ corrected ┴ Bool: true
me ┼ SimpleExpectedReturns
│ w ┴ nothing
pdm ┼ Posdef
│ alg ┼ UnionAll: NearestCorrelationMatrix.Newton
│ kwargs ┴ @NamedTuple{}: NamedTuple()
c ┼ Float64: 0.5
decay ┼ ExpGerberIQDecay
│ e ┼ nothing
│ y ┴ nothing
sc ┼ nothing
kind ┼ BasicGerberIQ
│ d ┼ Float64: 2.0
│ n ┴ Float64: 0.5
alg ┼ Gerber1()
ex ┴ Transducers.ThreadedEx{@NamedTuple{}}: Transducers.ThreadedEx()
julia> factory(ce, StatsBase.Weights([1, 2, 3]))
GerberIQCovariance
ve ┼ SimpleVariance
│ me ┼ SimpleExpectedReturns
│ │ w ┴ StatsBase.Weights{Int64, Int64, Vector{Int64}}: [1, 2, 3]
│ w ┼ StatsBase.Weights{Int64, Int64, Vector{Int64}}: [1, 2, 3]
│ corrected ┴ Bool: true
me ┼ SimpleExpectedReturns
│ w ┴ StatsBase.Weights{Int64, Int64, Vector{Int64}}: [1, 2, 3]
pdm ┼ Posdef
│ alg ┼ UnionAll: NearestCorrelationMatrix.Newton
│ kwargs ┴ @NamedTuple{}: NamedTuple()
c ┼ Float64: 0.5
decay ┼ ExpGerberIQDecay
│ e ┼ nothing
│ y ┴ nothing
sc ┼ nothing
kind ┼ BasicGerberIQ
│ d ┼ Float64: 2.0
│ n ┴ Float64: 0.5
alg ┼ Gerber1()
ex ┴ Transducers.ThreadedEx{@NamedTuple{}}: Transducers.ThreadedEx()References
- [7] Gerber, Sander and Smyth, William and Markowitz, Harry and Miao, Yinsen and Ernst, Philip and Sargen, Paul, Squeezing Financial Noise: A Novel Approach to Covariance Matrix Estimation (December 01, 2025). Available at SSRN: https://ssrn.com/abstract=4986939 or http://dx.doi.org/10.2139/ssrn.4986939
PortfolioOptimisers.gerber_IQ_delta Function
gerber_IQ_delta(
xi::Number,
xj::Number,
axi::Number,
axj::Number,
decay::GerberIQDecayEstimator,
T::Integer,
k::Number,
sci::Number,
scj::Number,
kind::GerberIQCovarianceAlgorithm
) -> AnyComputes the Gerber IQ statistic for a single co-movement.
Arguments
xi: Return for asseti.xj: Return for assetj.axi: Absolute return for asseti.axj: Absolute return for assetj.decay: The decay estimator for the Gerber IQ statistic.T: The number of observations.k: The current observation.sci: Scaling factor for asseti.scj: Scaling factor for assetj.kind: The Gerber IQ co-movement template.
Returns
rho::Number: The Gerber IQ statistic.
Details
Calls
gerber_iq_weightto compute the Gerber IQ weight.Calls the functor of
decayto compute the decay factor.Returns the product of them both.
Related
References
- [7] Gerber, Sander and Smyth, William and Markowitz, Harry and Miao, Yinsen and Ernst, Philip and Sargen, Paul, Squeezing Financial Noise: A Novel Approach to Covariance Matrix Estimation (December 01, 2025). Available at SSRN: https://ssrn.com/abstract=4986939 or http://dx.doi.org/10.2139/ssrn.4986939
PortfolioOptimisers.gerber_IQ Function
gerber_IQ(
ce::GerberIQCovariance,
X::MatNum,
sd::ArrNum
) -> MatNumComputes the Gerber IQ statistic matrix using noise compression template in ce.kind and numerator/denominator definition according to ce.alg.
Arguments
ce: Covariance estimator.X: Data matrixobservations × featuresif thedimskeyword does not exist ordims = 1,features × observationswhendims = 2.sd: Standard deviation vector ofX, shaped to be consistent withX.
Returns
rho::MatNum: Correlation matrixfeatures x features.
Details
Calls
regenerate_decay.For each pair of assets
(i, j), iterate over all observations.For every pair at each observation computes the scaling factor for each asset with
gerber_iq_scaling, as well as counters for concordantpos, discordantneg, and–-forGerber1–-neutralnncounters are initialised to zero.If the absolute value of the returns of both assets is less than its respective scaled threshold
ce.c, the observation is skipped.If the absolute return of both assets is greater than its respective scaled threshold
ce.c. a. If the movement is concordant (both returns have the same sign), the concordant counter is incremented according togerber_IQ_delta. b. If the movement is discordant (both returns have different signs), the discordant counter is incremented according togerber_IQ_delta. c. ForGerber1, if the neither of the previous conditions are met, it means only one of the absolute returns is greater than its respective scaledce.c, so the neutral counter is incremented.For each
GerberCovarianceAlgorithm, the GerberIQ statistics is computed as follows: a.Gerber0:(pos - neg) / (pos + neg)b.Gerber1:(pos - neg) / (pos + neg + nn)c.Gerber2: The numerator is computes as when usingGerber0, but the resulting matrix is standardised by dividing each element by the geometric mean of the corresponding diagonal elements.
Related
cor(ce::GerberIQCovariance, X::MatNum; dims::Int = 1, kwargs...)cov(ce::GerberIQCovariance, X::MatNum; dims::Int = 1, kwargs...)
References
- [7] Gerber, Sander and Smyth, William and Markowitz, Harry and Miao, Yinsen and Ernst, Philip and Sargen, Paul, Squeezing Financial Noise: A Novel Approach to Covariance Matrix Estimation (December 01, 2025). Available at SSRN: https://ssrn.com/abstract=4986939 or http://dx.doi.org/10.2139/ssrn.4986939
Statistics.cor Method
Statistics.cor(ce::GerberIQCovariance, X::MatNum; dims::Int = 1, kwargs...) -> MatNum
Compute the Gerber IQ correlation matrix.
This method computes the Gerber IQ correlation matrix for the input data matrix X. The mean and standard deviation vectors are computed using the estimator's expected returns and variance estimators. The Gerber IQ correlation is then computed via gerber_IQ.
Arguments
ce: Gerber IQ covariance estimator.ce::GerberIQCovariance: Compute the unstandardised Gerber IQ correlation matrix.
X: Data matrix (observations × assets).dims: Dimension along which to perform the computation.kwargs...: Additional keyword arguments passed to the mean and standard deviation estimators.
Returns
rho::MatNum: The Gerber IQ correlation matrix.
Validation
dimsis either1or2.
Related
References
- [7] Gerber, Sander and Smyth, William and Markowitz, Harry and Miao, Yinsen and Ernst, Philip and Sargen, Paul, Squeezing Financial Noise: A Novel Approach to Covariance Matrix Estimation (December 01, 2025). Available at SSRN: https://ssrn.com/abstract=4986939 or http://dx.doi.org/10.2139/ssrn.4986939
Statistics.cov Method
Statistics.cov(ce::GerberIQCovariance, X::MatNum; dims::Int = 1, kwargs...) -> MatNum
Compute the Gerber IQ covariance matrix.
This method computes the Gerber IQ covariance matrix for the input data matrix X. The mean and standard deviation vectors are computed using the estimator's expected returns and variance estimators. The Gerber IQ correlation is then computed via gerber_IQ.
Arguments
ce: Gerber IQ covariance estimator.ce::GerberIQCovariance: Compute the Gerber IQ covariance matrix.
X: Data matrix (observations × assets).dims: Dimension along which to perform the computation.kwargs...: Additional keyword arguments passed to the mean and standard deviation estimators.
Returns
sigma::MatNum: The Gerber IQ covariance matrix.
Validation
dimsis either1or2.
Related
References
- [7] Gerber, Sander and Smyth, William and Markowitz, Harry and Miao, Yinsen and Ernst, Philip and Sargen, Paul, Squeezing Financial Noise: A Novel Approach to Covariance Matrix Estimation (December 01, 2025). Available at SSRN: https://ssrn.com/abstract=4986939 or http://dx.doi.org/10.2139/ssrn.4986939