RF {FMradio} | R Documentation |
Redundancy filtering of a square (correlation) matrix
Description
RF
is a function that performs redundancy filtering (RF) of a square (correlation) matrix.
Usage
RF(R, t = .95)
Arguments
R |
Square (correlation) |
t |
A scalar |
Details
Radiomic features can be very strongly correlated. The sample correlation matrix on extracted radiomic features will then often display strong collinearity. The collinearity may be so strong as to imply redundant information, in the sense that some entries will approach perfect (negative) correlation. Hence, one may wish to perform redundancy-filtering on the raw sample correlation matrix in such situations.
The RF
function uses an Algorithm from Peeters et al. (2019) to remove the minimal number of redundant features under absolute marginal correlation threshold t
.
We recommend setting \mathrm{t} \in [.9,.95]
.
Details of the algorithm can be found in Peeters et al. (2019).
The function returns a redundancy-filtered correlation matrix
.
This return output may subsequently be used in the subSet
function.
This is a convenience function that subsets a dataset to the features retained after redundancy-filtering.
Value
Returns a redundancy-filtered matrix
.
Note
While geared towards the redundancy filtering of correlation matrices, the function is quite general, in the sense that it can be used to filter any square
matrix
.When the input matrix
R
is a correlation matrix, then argumentt
should satisfy-1 < \mathrm{t} < 1
, for the return matrix to be sensical for further analysis.
Author(s)
Carel F.W. Peeters <cf.peeters@vumc.nl>
References
Peeters, C.F.W. et al. (2019). Stable prediction with radiomics data. arXiv:1903.11696 [stat.ML].
See Also
Examples
## Generate some (high-dimensional) data
## Get correlation matrix
p = 25
n = 10
set.seed(333)
X = matrix(rnorm(n*p), nrow = n, ncol = p)
colnames(X)[1:25] = letters[1:25]
R <- cor(X)
## Redundancy visualization, at threshold value .9
radioHeat(R, diag = FALSE, threshold = TRUE, threshvalue = .9)
## Redundancy-filtering of correlation matrix
Rfilter <- RF(R, t = .9)
dim(Rfilter)