saezlab / mistyR

Multiview Intercellular SpaTial modeling framework
https://saezlab.github.io/mistyR/
GNU General Public License v3.0
48 stars 11 forks source link

Visualization of final model #25

Closed wangyiqing50 closed 1 year ago

wangyiqing50 commented 2 years ago

Since the final model is a linear combination of each view, I was wondering if it makes sense to visualize the final model and how.

For example, the importance which could be a weighted sum of each view by their contribution. In this case I don't care if they are colocalized or if they are neighbors. Just want to see which targets are spatially dependent with predictors.

jtanevski commented 2 years ago

When the importances are calculated the significance of the view contribution for that target is taken into account. You can choose to plot the heatmap per view without any cutoff or trim and you will get all predictor-target importances. All individual and unweighted importances are stored in the importances element in the results list and the contributions are stored in the contributions and the contributions.stats elements. You can use them to aggregate the available information in any way you find useful. See the implementation of the function _aggregateresults as an example. I think that also the code of the _collectresults function starting at line 200 would be a good place to check. If i haven't answered your question, can you be a bit more specific please?