Calculate dependence metrics for modified mixing matrices and confounds - #1350
Calculate dependence metrics for modified mixing matrices and confounds#1350tsalo wants to merge 18 commits into
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #1350 +/- ##
==========================================
+ Coverage 90.28% 90.36% +0.08%
==========================================
Files 30 30
Lines 4712 4776 +64
Branches 784 791 +7
==========================================
+ Hits 4254 4316 +62
- Misses 309 312 +3
+ Partials 149 148 -1 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
I can work on the test coverage once we decide if we want to move forward with this. |
| LGR.info("Generating metrics for TEDORT-orthogonalized mixing matrix") | ||
| orig_verbose = io_generator.verbose | ||
| io_generator.verbose = False | ||
| orth_component_table, _ = metrics.collect.generate_metrics( |
There was a problem hiding this comment.
One thing I learned from trying out this branch on real data is that the dependence metrics will change only for accepted components when using the orthogonalized mixing matrix. Given how orthogonalization is meant to be used (i.e., you would do denoising using only the orthogonalized rejected components), it might make more sense to calculate the dependence metrics on a mixing matrix that only contains the orthogonalized rejected components.
There was a problem hiding this comment.
I tried generating the metrics using just the orthogonalized rejected components, and the dependence metrics stayed the same as the original values for those components! I'm a little surprised.


Closes #1300 and closes #1341.
Changes proposed in this pull request:
generate_metricson the following:--tedortis enabled.--gscontrol miris enabled.gsrandmirtime series if--gscontrol gsrand/ormirare enabled.use_multivariateargument togenerate_metrics. It should be true for mixing matrices and false for external regressors and confounds. It shouldn't matter for PCA, since orthogonal components should produce the same component weights whether or not a multivariate model is used.