-
Notifications
You must be signed in to change notification settings - Fork 8
Open
Labels
Description
Hi,
I was planning to use prinComp and grid2PCs to implement a sort of cross-validation for the use of PCA with seasonal forecasts.
Here the grid test file I have used: https://www.dropbox.com/s/a699e6wq4zae0vm/monthly-erain.rda?dl=0
Here a reproducible example:
rm(list = ls())
library(transformeR)
load(file = 'monthly-erain.rda')
orig_princomp <- prinComp(obs, 4)
get_pc <- PC2grid(orig_princomp)
# reapply on the same grid
reapplied_princomp = grid2PCs(orig_princomp, obs)
# compare PCs
plot(reapplied_princomp[[1]][,1] ~ get_pc$Data[1,,1,1])If I use grid2PCs on the same grid file used to compute the prinComp I would expect to have the same identical PCs, am I wrong? Instead they are similar but not identical, what happens here?