The R Shiny app CsppaRshiny performs machine learning analysis and visualization of cellular spatial point patterns under hypercaloric diet shifts, and it is based on Csppa R-package.
The application visualizes spatial point pattern density plots in 3D and 2D, allowing flexibility in representing the data and emphasizing the question of interest. It also provides for overall and local significance analysis of spatial point pattern densities, employing several statistical approaches.
K-Nearest Neighbour and Random Forest classification algorithms are implemented to compare the grouping of the cells expressing different markers within and between the diets. Additionally, the correlation and spatial autocorrelation of cells expressing different markers can be compared using the Mantel and Moran's I tests, respectively.
Here, we focus on astrocytes from the arcuate nucleus of the mouse brain and the expression of Gfap and Aldh1l1 genes, recovering spatial point patterns under a standard chow (SC), 5-day, and 15-day high-fat high-sugar (HFHS) diets. The R-package Csppa allows for assessing whether these astrocyte populations are spatially organized and whether they tend to form local identical clusters in response to an HFHS diet over time. The algorithm evaluates the spatial coherence of each astrocytic subtype—reflecting the similarity between neighbouring cells—under different conditions (SC, 5d, or 15d HFHS diet) by applying Moran’s I spatial autocorrelation coefficient, a recognised measure of spatial dispersion. Additionally, the use of a random forest classifier enables the delineation of feature space partitions shared by astrocytes expressing Gfap and Aldh1l1 across experimental groups.
To run the CsppaRshiny app locally, ensure all dependencies are installed. Open the app.R file in RStudio and click Run App. Before launching, either load the functions from the R folder into RStudio or install the R-package Csppa.
Data required for cellular spatial point pattern analysis will be deposited online soon:
| Data type | Link to the data | Code to get the data |
|---|---|---|
| Aldh1l1 only | link | link |
| Gfap only | link | link |
| Double positive | link | link |
Please see the following notebook for detailed examples of what you can do with CsppaRshiny:
CsppaRshiny is distributed under the MIT license. Details about the license of CsppaRshiny are provided in the LICENSE file. Please read the license before using CsppaRshiny.
Publications related to CsppaRshiny include:
-
Lutomska, L.M., Miok, V., Krahmer, N., González García, I., Gruber, T., Le Thuc, O., De Bernardis Murat, C., Legutko, B., Sterr, M., Saher, G., Lickert, H., Ussar, S., Tschöp, M., Lutter, D., García-Cáceres, C. (2022), Diet triggers specific responses of hypothalamic astrocytes in time and region dependent manner, Glia 70 (10), 1795-2008.
-
Lutomska, L.M., Miok, V., Krahmer, N., González García, I., Gruber, T., Le Thuc, O., De Bernardis Murat, C., Legutko, B., Sterr, M., Saher, G., Lickert, H., Ussar, S., Tschöp, M., Lutter, D., García-Cáceres, C.(2021), Hypercaloric diet selectively triggers a transient molecular rearrangement of astrocytes in the arcuate nucleus, bioRxiv, 4(1).
Please cite the relevant publications if you use CsppaRshiny.

