Intravital calcium imaging of meningeal macrophages reveals niche-specific dynamics and aberrant responses to brain hyperexcitability.
The 20 matches · 8 of them tie a paragraph to a whole file, not to given lines: weak matches, whose lines are not tinted
- [1] § Methods › Quantification and statistical analysis › General linear models ↔ GLM_LocoFluorescence.m, lines 47–170 · score 0.79 · GLMnet, temporal shift, frame rate, locomotion state, fluorescence, Gaussian
- [2] § Methods › Quantification and statistical analysis › Clustering of Ca2+ dynamics ↔ clusterCa2Signals.m, lines 43–87 · score 0.78 · peak prominence, Fourier Transform, dominant frequency, Elbow, smooth, optimal
- [3] § Methods › Quantification and statistical analysis › General linear models ↔ GLM_2_DiamFluorescence.m, lines 48–183 · score 0.77 · GLMnet, temporal shift, frame rate, fluorescence, Gaussian, trained
- [4] § Results › Characterizing macrophage Ca2+ signaling features in homeostatic brain meninges ↔ clusterCa2Signals.m, lines 43–87 · score 0.71 · Power spectrum density, frequency domain features, peak detection, PSD, Clustering, square
- [5] § Results › An acute aberrant pro-inflammatory brain hyperexcitability event drives diverse Ca2+ dynamics in meningeal macrophages ↔ chiSquare_residuals.m, the whole file · a weak match · score 0.70 · Chi square, persistent increase, persistent decrease, acute increase, PreCSD, post CSD
- [6] § Methods › Quantification and statistical analysis › Analysis of locomotion ↔ TrainLocoHMM.m, lines 1–56 · score 0.69 · Hidden Markov Model, locomotion state, cm, trained, velocity, speed
- [7] § Methods › Quantification and statistical analysis › Analysis of locomotion ↔ GetLocoState.m, the whole file · a weak match · score 0.69 · Hidden Markov Model, locomotion state, hmmviterbi, trained, velocity, speed
- [8] § Methods › Quantification and statistical analysis › Analysis of CSD-related changes in macrophage Ca2+ dynamics ↔ clusterParams_CSD.m, the whole file · a weak match · score 0.66 · duringCSD, postCSD, preCSD, event rate, phases, acute
- [9] § Methods › Quantification and statistical analysis › Analysis of CSD-related changes in macrophage Ca2+ dynamics ↔ classifyEventRatesCSD2.m, the whole file · a weak match · score 0.66 · duringCSD, postCSD, preCSD, event rate, phases, cell
- [10] § Results › An acute aberrant pro-inflammatory brain hyperexcitability event drives diverse Ca2+ dynamics in meningeal macrophages ↔ AQuA2_6_Waves_CSD.m, lines 28–79 · score 0.66 · postCSD, preCSD, CSD event, wave, event rate, acute
- [11] § Results › An acute aberrant pro-inflammatory brain hyperexcitability event drives diverse Ca2+ dynamics in meningeal macrophages ↔ clusterWaves_eventRate6_CSD.m, the whole file · a weak match · score 0.65 · postCSD, preCSD, CSD event, wave, event rate, acute
- [12] § Methods › Quantification and statistical analysis › Vascular signals ↔ GetVesselProfile.m, the whole file · a weak match · score 0.64 · vessel profile, Radon transform, polygons, pixels, ROI
- [13] § Results › Dural perivascular macrophage Ca2+ activity is tuned to behaviorally driven dural vasomotion ↔ plotGLM_locoDiamFluor.m, lines 7–128 · score 0.56 · fluorescence signal, deviance explained, locomotion state, GLM, model, zero
- [14] § Results › An acute aberrant pro-inflammatory brain hyperexcitability event drives diverse Ca2+ dynamics in meningeal macrophages ↔ AQuA2_6_Waves_CSD.m, lines 28–79 · score 0.55 · Chi square, acute response, preCSD, post CSD, NP, bar
- [15] § Results › CGRP receptor signaling mediates CSD-evoked persistent increase in meningeal macrophage Ca2+ activity ↔ plotRasterByCluster.m, the whole file · a weak match · score 0.54 · acute increase, preCSD, post CSD, raster, event rate, BIBN
- [16] § Results › Characterizing macrophage Ca2+ signaling features in homeostatic brain meninges ↔ AQuA2_5_cellNetwork_multiExpt_CSD.m, lines 487–526 · score 0.52 · concurrent events, simultaneous event, networks, distances, delay, duration
- [17] § Results › Characterizing macrophage Ca2+ signaling features in homeostatic brain meninges ↔ plotFFT.m, the whole file · a weak match · score 0.52 · frequency spectra, dominant frequency, magnitude, noise, signal
- [18] § Methods › Quantification and statistical analysis › Ca2+ signal detection pipeline ↔ AQuA2_5_cellNetwork_multiExpt_baseline.m, lines 373–420 · score 0.51 · spatial resolution, AQuA2, pixel, propagation, event, cell
- [19] § Methods › Quantification and statistical analysis › Statistical analysis ↔ AQuA2_6_Waves.m, lines 93–177 · score 0.51 · Mann Whitney, Chi square, sum
- [20] § Methods › Quantification and statistical analysis › Statistical analysis ↔ AQuA2_6_Waves_CSD.m, lines 569–650 · score 0.51 · Mann Whitney, Chi square, sum
Paper
Loaded from Europe PMC by your browser, not stored by OSCR: doi.org · Europe PMC
The paper is loaded when this pane is shown.
The authors' code
MATLAB · 689 lines · 27 KB · GPL-3.0 · 3 matches
- %% create clusters based on preCSD x duringCSD and preCSD x postCSD response
- clear all;
- experiment = input('CSD or BIBN-CSD?: ', 's'); % 's' means input as string
- durationCSDmin = input('Enter duration of duringCSD in minutes (1 or 2): ');
- if strcmp(experiment, 'CSD')
- load('D:\2photon\Simone\Simone_Macrophages\AQuA2_Results\fullCraniotomy\CSD\corrected_for_pinprick\0.49resolution_correct\AQuA2_data_fullCraniotomy_CSD.mat');
- if durationCSDmin == 1 %due to mismatch of combinedTable and eventHz_byCell, which filters out events that happen after 61min
- toRemove = [22,23,40,80,81,90,100,129,143,144,145,214,215,216,233,248,249,250];
- combinedTable_complete(toRemove, :) = [];
- elseif durationCSDmin == 2 %due to mismatch of combinedTable and eventHz_byCell, which filters out events that happen after 62min
- toRemove = [22,23,40,80,81,100,129,144,145,214,215,216,233,248,249,250];
- combinedTable_complete(toRemove, :) = [];
- end
- elseif strcmp(experiment, 'BIBN-CSD')
- if durationCSDmin == 1
- load('D:\2photon\Simone\Simone_Macrophages\AQuA2_Results\fullCraniotomy\BIBN\AQuA2_data_fullCraniotomy_BIBN_CSD-1min-duringCSD.mat');
- toRemove = 43;
- combinedTable_complete(toRemove, :) = [];
- elseif durationCSDmin == 2
- load('D:\2photon\Simone\Simone_Macrophages\AQuA2_Results\fullCraniotomy\BIBN\AQuA2_data_fullCraniotomy_BIBN-CSD_2min-duringCSD.mat');
- toRemove = 43; %same as 1min-duringCSD
- combinedTable_complete(toRemove, :) = [];
- end
- end
- %% CLUSTER BY EVENT RATE (9)
- %
- % % Extract cell types and cluster CSD events
- % cellTypes = combinedTable_complete{:, 13};
- % cells = ["cells"; "perivascular"; "non-perivascular"];
- %
- % % 9 clusters
- % [eventRate_directions, eventRate_directionCounts, eventRate_directionLabels, eventRate_clusterID, rates_mHz, rates_mHz_clusterID] = clusterWaves_eventRate9_CSD(eventHz_byCell, cellTypes);
- % eventRate_clusters = [eventRate_directions; eventRate_directionCounts];
- % eventRate_clusters = [eventRate_clusters, cells];
- %
- % combinedTable_clusters = addvars(combinedTable_complete, eventRate_clusterID, 'NewVariableNames', 'eventRate_clusterID');
- %
- % % Assuming rates_mHz is Nx3 (columns: preCSD, duringCSD, postCSD)
- % combinedTable_clusters = addvars(combinedTable_clusters, ...
- % rates_mHz(:,1), rates_mHz(:,2), rates_mHz(:,3), ...
- % 'NewVariableNames', {'eventRate_preCSD', 'eventRate_duringCSD', 'eventRate_postCSD'});
- %
- % rates_mHz_clusterID_sorted = sortrows(rates_mHz_clusterID, 4); % descending sort by column 4
- %
- % % Chi-square - comparing the distribution between perivascular vs non-perivascular for each cluster
- % [p_values_byCluster, stats_byCluster] = chi_square_plot(eventRate_directionCounts);
- %
- % % Run Chi-square test of independence - testing whether cluster and cell type are independent
- % [~, p_values_All, stats_All] = chi2gof_from_table(eventRate_directionCounts);
- %
- % % Chi-square test by ACUTE response
- % [p_values_Acute, stats_Acute] = chi_square_by_acuteResponse(eventRate_directionCounts, 3);
- %
- % % Chi-square test by CHRONIC response
- % [p_values_Chronic, stats_Chronic] = chi_square_by_chronicResponse(eventRate_directionCounts);
- %
- % % Plot heatmap of conditional probabilities (3x3)
- % [All_matrix, P_matrix, NP_matrix] = plotConditionalProbabilities(eventRate_directionCounts, outputDir);
- %
- % Distributions
- % Plot distribution Cell type x Cluster
- [clustersPercentage, roundedData] = plotClusterDistributionByCellType(eventRate_clusters, eventRate_directions, cells, outputDir);
- % Plot distribution clusters x FOV
- plotFOVDistributionByCluster(combinedTable_clusters, outputDir);
- % Plot distribution FOV x cluster
- plotClusterDistributionByFOV(combinedTable_clusters, outputDir);
- %
- % %create heatmap
- % plotClusterHeatmap_FOVnormalized(combinedTable_clusters, [1:9], sortedFileNames, outputDir); %[1,2, 5:9] BIBN by FOV
- % plotClusterHeatmap_zscore(combinedTable_clusters, [2,4,9], outputDir); %[1,2,3,1,4,7,3,6,9]
- %
- % % stacked bars
- % probs = compute_Clusterwise_probabilities(eventRate_directionCounts);
- % plotStackedDirectionGroups(eventRate_directionCounts, outputDir)
- %% CLUSTER by EVENT RATE (6)
- % Extract cell types and cluster CSD events
- cellTypes = combinedTable_complete{:, 13};
- cells = ["cells"; "perivascular"; "non-perivascular"];
- % 6 cluster
- [eventRate_directions, eventRate_directionCounts, eventRate_directionLabels, eventRate_clusterID, rates_mHz, rates_mHz_clusterID] = clusterWaves_eventRate6_CSD(eventHz_byCell, cellTypes);
- eventRate_clusters = [eventRate_directions; eventRate_directionCounts];
- eventRate_clusters = [eventRate_clusters, cells];
- combinedTable_clusters = addvars(combinedTable_complete, eventRate_clusterID, 'NewVariableNames', 'eventRate_clusterID');
- %
- % cluster6 = [];
- % for cell = 1:size(combinedTable_clusters,2)
- % if combinedTable_clusters.eventRate_clusterID(cell) == 6
- % cellID = [combinedTable_clusters.("Cell ID")(cell); combinedTable_clusters.("Number of Events")(cell); combinedTable_clusters.fileNameColumn(cell); combinedTable_clusters.("eventRate_clusterID")(cell)];
- % cluster6 = [cluster6; cellID];
- % end
- % end
- % Find rows where eventRate_clusterID == 6
- mask = combinedTable_clusters.eventRate_clusterID == 6;
- % Extract relevant columns into a new table
- cluster6 = combinedTable_clusters(mask, ...
- {'Cell ID','Number of Events','fileNameColumn','eventRate_clusterID'});
- % % Example 1: Acute Increase
- % AcuteIncrease = [7 7; 3 4];
- % plotChi2Residuals(AcuteIncrease, {'P','NP'}, {'Persistent Increase','Persistent Decrease'});
- %
- % % Example 2: Persistent Increase
- % PersistentIncrease = [7 11; 3 34];
- % plotChi2Residuals(PersistentIncrease, {'P','NP'}, {'Acute Increase','Acute No Change'});
- %
- % % Example 3: Persistent Decrease
- % PersistentDecrease = [7 25; 4 110];
- % plotChi2Residuals(PersistentDecrease, {'P','NP'}, {'Acute Increase','Acute No Change'});
- %
- % max dFF during CSD
- preCSD_maxDFF = table2cell(paramTables_allPhases.Max_dFF(:,2));
- duringCSD_maxDFF = table2cell(paramTables_allPhases.Max_dFF(:,3));
- postCSD_maxDFF = table2cell(paramTables_allPhases.Max_dFF(:,4));
- % Assuming rates_mHz is Nx3 (columns: preCSD, duringCSD, postCSD)
- combinedTable_clusters = addvars(combinedTable_clusters, ...
- rates_mHz(:,1), rates_mHz(:,2), rates_mHz(:,3), preCSD_maxDFF, duringCSD_maxDFF, postCSD_maxDFF,...
- 'NewVariableNames', {'eventRate_preCSD', 'eventRate_duringCSD', 'eventRate_postCSD', 'preCSD_maxDFF', 'duringCSD_maxDFF', 'postCSD_maxDFF'});
- preCSD_maxDFF_all = [];
- for x = 1:size(combinedTable_clusters,1)
- if ismember(combinedTable_clusters.eventRate_clusterID(x), [3 6])
- preCSD_maxDFF_x = combinedTable_clusters.preCSD_maxDFF(x);
- preCSD_maxDFF_all = [preCSD_maxDFF_all; preCSD_maxDFF_x];
- end
- end
- duringCSD_maxDFF_all = [];
- for x = 1:size(combinedTable_clusters,1)
- if ismember(combinedTable_clusters.eventRate_clusterID(x), [1 2 3])
- duringCSD_maxDFF_x = combinedTable_clusters.duringCSD_maxDFF(x);
- duringCSD_maxDFF_all = [duringCSD_maxDFF_all; duringCSD_maxDFF_x];
- end
- end
- postCSD_maxDFF_all = [];
- for x = 1:size(combinedTable_clusters,1)
- if ismember(combinedTable_clusters.eventRate_clusterID(x), [3 6])
- postCSD_maxDFF_x = combinedTable_clusters.postCSD_maxDFF(x);
- postCSD_maxDFF_all = [postCSD_maxDFF_all; postCSD_maxDFF_x];
- end
- end
- % % without separating by cell type
- % rate_cluster_acuteIncrease = []; %2
- % rate_cluster_chronicIncrease = []; %4
- % rate_cluster_chronicDecrease = []; %6
- %
- % rate_cluster_AllacuteIncrease = []; %1,2,3
- % rate_cluster_AllchronicIncrease = []; %1,4
- % rate_cluster_AllchronicDecrease = []; %3,6
- %
- % for cellCluster = 1:size(rates_mHz, 1)
- % clusterID = combinedTable_clusters.eventRate_clusterID(cellCluster);
- % currentCell_rate = rates_mHz(cellCluster, :); % row vector
- % cellType = cellTypes(cellCluster);
- %
- % % Individual clusters
- % if clusterID == 2
- % rate_cluster_acuteIncrease = [rate_cluster_acuteIncrease; [currentCell_rate, cellType]];
- % end
- % if clusterID == 4
- % rate_cluster_chronicIncrease = [rate_cluster_chronicIncrease; [currentCell_rate, cellType]];
- % end
- % if clusterID == 6
- % rate_cluster_chronicDecrease = [rate_cluster_chronicDecrease; [currentCell_rate, cellType]];
- % end
- %
- % % Combined clusters
- % if ismember(clusterID, [1,2,3])
- % rate_cluster_AllacuteIncrease = [rate_cluster_AllacuteIncrease; [currentCell_rate, cellType]];
- % end
- % if ismember(clusterID, [1, 4])
- % rate_cluster_AllchronicIncrease = [rate_cluster_AllchronicIncrease; [currentCell_rate, cellType]];
- % end
- % if ismember(clusterID, [3, 6])
- % rate_cluster_AllchronicDecrease = [rate_cluster_AllchronicDecrease; [currentCell_rate, cellType]];
- % end
- % end
- % === Initialize ===
- rate_cluster_acuteIncrease_peri = [];
- rate_cluster_acuteIncrease_nonperi = [];
- rate_cluster_chronicIncrease_peri = [];
- rate_cluster_chronicIncrease_nonperi = [];
- rate_cluster_chronicDecrease_peri = [];
- rate_cluster_chronicDecrease_nonperi = [];
- rate_cluster_AllacuteIncrease_peri = [];
- rate_cluster_AllacuteIncrease_nonperi = [];
- rate_cluster_AllchronicIncrease_peri = [];
- rate_cluster_AllchronicIncrease_nonperi = [];
- rate_cluster_AllchronicDecrease_peri = [];
- rate_cluster_AllchronicDecrease_nonperi = [];
- % === Loop through each cell ===
- for cellCluster = 1:size(rates_mHz, 1)
- clusterID = combinedTable_clusters.eventRate_clusterID(cellCluster);
- currentCell_rate = rates_mHz(cellCluster, :); % row vector
- cellType = cellTypes(cellCluster); % 0 = peri, 2 = non-peri
- % --- Individual clusters ---
- if clusterID == 2
- if cellType == 0
- rate_cluster_acuteIncrease_peri = [rate_cluster_acuteIncrease_peri; currentCell_rate];
- elseif cellType == 2
- rate_cluster_acuteIncrease_nonperi = [rate_cluster_acuteIncrease_nonperi; currentCell_rate];
- end
- elseif clusterID == 4
- if cellType == 0
- rate_cluster_chronicIncrease_peri = [rate_cluster_chronicIncrease_peri; currentCell_rate];
- elseif cellType == 2
- rate_cluster_chronicIncrease_nonperi = [rate_cluster_chronicIncrease_nonperi; currentCell_rate];
- end
- elseif clusterID == 6
- if cellType == 0
- rate_cluster_chronicDecrease_peri = [rate_cluster_chronicDecrease_peri; currentCell_rate];
- elseif cellType == 2
- rate_cluster_chronicDecrease_nonperi = [rate_cluster_chronicDecrease_nonperi; currentCell_rate];
- end
- end
- % --- Combined clusters ---
- if ismember(clusterID, [1, 2, 3]) % All acute increase
- if cellType == 0
- rate_cluster_AllacuteIncrease_peri = [rate_cluster_AllacuteIncrease_peri; currentCell_rate];
- elseif cellType == 2
- rate_cluster_AllacuteIncrease_nonperi = [rate_cluster_AllacuteIncrease_nonperi; currentCell_rate];
- end
- end
- if ismember(clusterID, [1, 4]) % All chronic increase
- if cellType == 0
- rate_cluster_AllchronicIncrease_peri = [rate_cluster_AllchronicIncrease_peri; currentCell_rate];
- elseif cellType == 2
- rate_cluster_AllchronicIncrease_nonperi = [rate_cluster_AllchronicIncrease_nonperi; currentCell_rate];
- end
- end
- if ismember(clusterID, [3, 6]) % All chronic decrease
- if cellType == 0
- rate_cluster_AllchronicDecrease_peri = [rate_cluster_AllchronicDecrease_peri; currentCell_rate];
- elseif cellType == 2
- rate_cluster_AllchronicDecrease_nonperi = [rate_cluster_AllchronicDecrease_nonperi; currentCell_rate];
- end
- end
- end
- % Initialize group labels
- eventRateGroup = strings(height(combinedTable_clusters), 1);
- % Assign group based on event rate
- eventRateGroup(combinedTable_clusters.eventRate_preCSD == 0) = "0";
- eventRateGroup(combinedTable_clusters.eventRate_preCSD > 0 & combinedTable_clusters.eventRate_preCSD <= 1) = "0-1";
- eventRateGroup(combinedTable_clusters.eventRate_preCSD > 1) = ">1";
- % Convert to categorical
- combinedTable_clusters.eventRateGroup = categorical(eventRateGroup, {'0', '0-1', '>1'});
- % Use groupcounts on the new categorical variable
- groupCounts = groupcounts(combinedTable_clusters.eventRateGroup);
- total = sum(groupCounts);
- groupPercents = 100 * groupCounts / total;
- % Plot heatmap of conditional probabilities (3x3)
- [All_matrix, P_matrix, NP_matrix] = plotCluster6Distribution(eventRate_directionCounts, outputDir);
- %% CLUSTER by EVENT COUNT (6)
- % cellTypes = combinedTable_complete{:, 13};
- % cells = ["cells"; "perivascular"; "non-perivascular"];
- % [eventCounts_directions, eventCounts_directionCounts, eventCounts_directionLabels, counts_clusterID, eventCounts, eventCounts_clusterID] = clusterWaves_eventCount6_CSD(events_byCell_all, cellTypes);
- % eventCounts_clusters = [eventCounts_directions; eventCounts_directionCounts];
- % eventCounts_clusters = [eventCounts_clusters, cells];
- %
- % combinedTable_clusters = addvars(combinedTable_complete, counts_clusterID, 'NewVariableNames', 'counts_clusterID');
- %
- % % Plot heatmap of conditional probabilities (3x3)
- % [All_matrix, P_matrix, NP_matrix] = plotCluster6Distribution(eventCounts_directionCounts, outputDir);
- %% CLUSTER BY dFF (9)
- % cellTypes = combinedTable_complete{:, 13};
- % cells = ["cells"; "perivascular"; "non-perivascular"];
- % [dFF_directions, dFF_directionCounts, dFF_directionLabels, dFF_clusterID, phaseParams_dFF] = clusterParams_CSD(paramTables_allPhases, cellTypes);
- % dFF_clusters = [dFF_directions; dFF_directionCounts];
- % dFF_clusters = [dFF_clusters, cells];
- %
- % combinedTable_clusters = addvars(combinedTable_clusters, dFF_clusterID, 'NewVariableNames', 'dFF_clusterID');
- %
- % % Convert vectors to tables
- % T_eventRate = table(eventRate_clusterID, 'VariableNames', {'eventRate_clusterID'});
- % T_dFF = table(dFF_clusterID, 'VariableNames', {'dFF_clusterID'});
- %
- % dFF_clustersTable = [T_eventRate, T_dFF, phaseParams_dFF];
- %
- %
- % dFFcluster_acuteIncrease = []; %2
- % dFFcluster_chronicIncrease = []; %4
- % dFFcluster_chronicDecrease = []; %6
- %
- % dFFcluster_AllchronicIncrease = []; %1,4
- % dFFcluster_AllchronicDecrease = []; %3,6
- %
- %
- % for cellCluster = 1:size(phaseParams_dFF, 1)
- % clusterID = dFF_clustersTable.eventRate_clusterID(cellCluster);
- % currentCell_dFF = phaseParams_dFF(cellCluster, :); % row vector
- %
- % % Individual clusters
- % if clusterID == 2
- % dFFcluster_acuteIncrease = [dFFcluster_acuteIncrease; currentCell_dFF];
- % end
- % if clusterID == 4
- % dFFcluster_chronicIncrease = [dFFcluster_chronicIncrease; currentCell_dFF];
- % end
- % if clusterID == 6
- % dFFcluster_chronicDecrease = [dFFcluster_chronicDecrease; currentCell_dFF];
- % end
- %
- % % Combined clusters
- % if ismember(clusterID, [1, 4])
- % dFFcluster_AllchronicIncrease = [dFFcluster_AllchronicIncrease; currentCell_dFF];
- % end
- % if ismember(clusterID, [3, 6])
- % dFFcluster_AllchronicDecrease = [dFFcluster_AllchronicDecrease; currentCell_dFF];
- % end
- % end
- %% Cluster 3x2 (up, none, down - acute & chronic)
- % cellTypes = combinedTable_complete{:, 13};
- % cells = ["cells"; "P"; "NP"];
- % [directions, acuteLabels, chronicLabels, acuteIDs, chronicIDs, acuteCounts, chronicCounts, rates_mHz] = clusterWaves_CSD_acute_chronic(eventHz_byCell, cellTypes);
- %
- % clustersAcute = [directions; acuteCounts];
- % clustersAcute = [clustersAcute, cells];
- % clustersChronic = [directions; chronicCounts];
- % clustersChronic = [clustersChronic, cells];
- %
- % combinedTable_clustersAcute = addvars(combinedTable_complete, acuteIDs, 'NewVariableNames', 'acuteIDs');
- % combinedTable_clustersChronic = addvars(combinedTable_complete, chronicIDs, 'NewVariableNames', 'chronicIDs');
- %
- % % Chi-square - comparing the distribution between perivascular vs non-perivascular for each cluster
- % [p_values_byCluster_acute, stats_byCluster_acute] = chi_square_plot(acuteCounts);
- % [p_values_byCluster_chronic, stats_byCluster_chronic] = chi_square_plot(chronicCounts);
- %
- % % Run Chi-square test of independence - testing whether cluster and cell type are independent
- % [~, p_values_All_acute, stats_All_acute] = chi2gof_from_table(acuteCounts);
- % [~, p_values_All_chronic, stats_All_chronic] = chi2gof_from_table(chronicCounts);
- %
- % % Distribution Cell type x Cluster
- % [clustersPercentage_acute, roundedData_acute] = plotClusterDistributionByCellType(clustersAcute, directions, cells, outputDir);
- % figure; bar(roundedData_acute,'stacked','DisplayName','roundedData_acute')
- % legend(directions); xticklabels(cells(2:3)); title('Acute response by cell type')
- %
- % [clustersPercentage_chronic, roundedData_chronic] = plotClusterDistributionByCellType(clustersChronic, directions, cells, outputDir);
- % figure; bar(roundedData_chronic,'stacked','DisplayName','roundedData_chronic')
- % legend(directions); xticklabels(cells(2:3)); title('Chronic response by cell type')
- %
- % % Heatmaps ACUTE vs CHRONIC
- % plotClusterHeatmap_zscore(combinedTable_clustersAcute, 1:2);
- % plotClusterHeatmap_zscore(combinedTable_clustersChronic, 1:2);
- %
- % % Compare baseline between chronic clusters %1,4,7x3,6,9
- % preHz = str2double(eventHz_byCell(:, 2));
- % preHz_cluster = [preHz, combinedTable_clusters.eventRate_clusterID];
- % compareBaselineRates(preHz, acuteIDs, chronicIDs)
- %% EVENT raster plot
- % Process startingFrames for raster plot
- allEmpty = all(cellfun(@isempty, startingFrames_byCell_all(:, 2:5)), 2);
- startingFrames_byCell_all(allEmpty, :) = []; %% Remove rows where all event phases are empty
- % Step 1: Flatten nested cells inside columns 2 to 5
- flattenedData = startingFrames_byCell_all;
- for i = 1:size(flattenedData, 1)
- for j = 2:5
- val = flattenedData{i, j};
- if iscell(val)
- % If it's a cell, convert to numeric vector
- try
- flattenedData{i, j} = cell2mat(val);
- catch
- flattenedData{i, j} = [];
- end
- end
- end
- end
- % Step 2: Convert to table
- startingFrames_table = cell2table(flattenedData, ...
- 'VariableNames', {'cellID', 'preCSD', 'duringCSD', 'postCSD', 'baseline_preCSD'});
- % Convert clusterID column to a table
- clusterID_table = table(combinedTable_clusters.eventRate_clusterID(:), 'VariableNames', {'eventRate_clusterID'});
- dFF_table = table(combinedTable_clusters.dFF(:), 'VariableNames', {'dFF'});
- % Horizontally concatenate the tables
- rasterTable = [startingFrames_table, clusterID_table, dFF_table];
- rasterTable_sorted = plotRasterByCluster(rasterTable, [2,4,6], experiment);
- %%
- load('D:\2photon\Simone\Simone_Macrophages\AQuA2_Results\fullCraniotomy\CSD\corrected_for_pinprick\0.49resolution_correct\AQuA2_data_fullCraniotomy_CSD.mat')
- cellLocation_indices = combinedTable{:,13};
- redLabel_indices = combinedTable{:,14};
- % By cell type
- perivascular_indices = cellLocation_indices == 0;
- nonPerivascular_indices = cellLocation_indices == 2;
- combinedTable_perivascular = combinedTable(perivascular_indices,:);
- combinedTable_nonPerivascular = combinedTable(nonPerivascular_indices,:);
- % dFF
- dFF_all = cell2mat(combinedTable.dFF); % Convert to matrix
- dFF_perivascular = cell2mat(combinedTable_perivascular.dFF);
- dFF_nonPerivascular = cell2mat(combinedTable_nonPerivascular.dFF);
- Fs = 1.03; % Sampling frequency
- %%
- combinedTable_sorted = sortrows(combinedTable, 'Max dFF', 'descend');
- dFF_all_sorted = cell2mat(combinedTable_sorted.dFF); % Convert to matrix
- dFF_all_sorted_preCSD = dFF_all_sorted(:, 1:1854);
- dFF_all_sorted_duringCSD = dFF_all_sorted(:, 1855:1917); %60sec
- dFF_all_sorted_postCSD = dFF_all_sorted(:, 1918:3772);
- %dFF_all_sorted(38,:) = [];
- %dFF_check = dFF_all_sorted(:, 1700:2000);
- combinedTable_perivascular_sorted = sortrows(combinedTable_perivascular, 'Max dFF', 'descend');
- dFF_perivascular_sorted = cell2mat(combinedTable_perivascular_sorted.dFF);
- combinedTable_nonPerivascular_sorted = sortrows(combinedTable_nonPerivascular, 'Max dFF', 'descend');
- dFF_nonPerivascular_sorted = cell2mat(combinedTable_nonPerivascular_sorted.dFF);
- sortedMatrix = sortrows(dFF_all_sorted, 1855, "descend");
- %% plot heatmap for quick visualization
- minData = min(sortedMatrix(:));
- maxData = max(sortedMatrix(:));
- % all
- figure;
- imagesc(sortedMatrix);
- caxis([minData, maxData]);
- colormap(flipud(gray));
- colorbar;
- % sorte
- figure;
- imagesc(dFF_perivascular_sorted);
- caxis([minData, maxData]);
- colormap(flipud(gray));
- colorbar;
- % perivascular
- figure;
- imagesc(dFF_perivascular);
- caxis([minData, maxData]);
- colormap(flipud(gray));
- colorbar;
- % sorte
- figure;
- imagesc(dFF_perivascular_sorted);
- caxis([minData, maxData]);
- colormap(flipud(gray));
- colorbar;
- % non-perivascular
- figure;
- imagesc(dFF_nonPerivascular);
- caxis([minData, maxData]);
- colormap(flipud(gray));
- colorbar;
- % sorted
- figure;
- imagesc(dFF_nonPerivascular_sorted(1:65,:));
- caxis([minData, maxData]);
- colormap(flipud(gray));
- colorbar;
- %% Plot selected waves
- plotSelectedWaves_together(combinedTable, [88, 265, 330, 451], 'my_figure.eps');
- %% Categorize waves based on frequency, duration and amplitude of events
- cellTable = categorize_waves(combinedTable);
- %% Plot all curves
- %saveFolder = 'D:\2photon\Simone\Simone_Macrophages\AQuA2_Results\fullCraniotomy\baseline\dFF_waves';
- plot_dFF_waves(combinedTable, saveFolder, false);
- %% Visualize FFT - Fast Fourier Transformation
- % for each cell
- for w = 1:2 %size(dFF_all, 1)
- plotFFT(dFF_all(w, :), Fs);
- end
- for w = 1:5 %size(dFF_all, 1)
- normalized_signal = zscore(dFF_all(w,:));
- plotFFT(normalized_signal, Fs);
- end
- % for all cells
- plotFFT_all(dFF_all, Fs); % dFF_all is your matrix of signals for all cells
- %% 1.Cluster based on wave shape
- maxClusters = 10; % Test up to 10 clusters
- optimalK = findOptimalClusters(dFF_all, maxClusters);
- [idx, count_k1, count_k2] = clusterWaves(dFF_all, optimalK);
- %% 2. Cluster based on SNR
- % Compute SNR
- snr_ma = computeSNR(dFF_all_sorted, 'ma', 5); % Using a window size of 5
- snr_fft = computeSNR(dFF_all_sorted, 'fft', 0.2); % Using 20% of frequencies as the cutoff
- maxClusters = 10; % Test up to 10 clusters
- [idx, clustered_cells, optimalK, count_k1, count_k2] = clusterSNR(snr_ma, maxClusters, dFF_all_sorted); % Use snr_ma or snr_fft
- %% 3. Cluster based on detrend, sgolayfilt, kmeans
- % https://www-science-org.ezp-prod1.hul.harvard.edu/doi/pdf/10.1126/scisignal.abe6909
- % 1. Apply Savitzky-Golay filtering only for visualization, not for clustering.
- % Optimize Sgolay params - takes very long time to optimize both params
- poly_orders = 1:6;
- frame_sizes = 5:2:927;
- [best_poly_order, best_frame_size, best_snr, best_filtered_signals] = optimizeSgolayParams(dFF_all, poly_orders, frame_sizes);
- % Check best frame size
- unique_vals_frame = unique(best_frame_size);
- counts = histc(best_frame_size, unique_vals_frame);
- figure; bar(unique_vals_frame, counts, 'FaceColor', 'b');
- % Check best poly order
- unique_vals_order = unique(best_poly_order);
- counts = histc(best_poly_order, unique_vals_order);
- figure; bar(unique_vals_order, counts, 'FaceColor', 'b');
- % 2. Cluster signals
- % Define your inputs
- maxClusters = 10; % Test up to 10 clusters
- poly_order = 6; % Range of polynomial orders for Savitzky-Golay filter
- frame_size = 7; % Frame sizes (odd numbers)
- % Assuming 'dFF_all' is your matrix of Ca2+ signals (cells x time points)
- [optimal_k, idx, features, cluster_means, count_k1, count_k2] = clusterCa2Signals(dFF_all_sorted, Fs, poly_order, frame_size, maxClusters);
- %% check differences between clusters
- darkPurple = [0.5, 0, 0.5]; % Dark purple
- darkGreen = [0, 0.5, 0];
- % SNR differences
- snr_1 = computeSNR(dFF_all_sorted(idx == 1,:), 'ma', 5); %'ma', 5 OR 'fft', 0.2
- snr_2 = computeSNR(dFF_all_sorted(idx == 2,:), 'ma', 5);
- % Median and IQR
- med1 = median(snr_1);
- med2 = median(snr_2);
- iqr1 = iqr(snr_1);
- iqr2 = iqr(snr_2);
- % Mann-Whitney U test
- [p, h, stats] = ranksum(snr_1, snr_2);
- fprintf('Mann-Whitney p = %.4f\n', p);
- % Plot
- figure;
- bar(1, med1, 'FaceColor', darkPurple); hold on;
- bar(2, med2, 'FaceColor', darkGreen);
- %bar([med1, med2], 'FaceColor', [0.2 0.6 0.8]); %'Color', colors
- % Set x-axis labels
- set(gca, 'XTick', [1 2], 'XTickLabel', {'Cluster 1', 'Cluster 2'});
- ylabel('Median SNR');
- % Error bars (IQR)
- hold on;
- errorbar([1, 2], [med1, med2], [iqr1, iqr2], '.k', 'LineWidth', 1.5);
- % Annotate p-value
- y_max = max([med1 + iqr1, med2 + iqr2]);
- text(1.5, y_max * 1.05, sprintf('Mann-Whitney p = %.4f', p),'HorizontalAlignment', 'center', 'FontSize', 12);
- hold off; box off;
- % cell location
- wave_location = zeros(size(idx,1), 2); % Preallocate for efficiency
- for cellIdx = 1:size(idx,1)
- wave_location(cellIdx, :) = [idx(cellIdx), combinedTable_sorted{cellIdx, "Cell location (0,perivascular;1,adjacent;2,none)"}];
- end
- tbl = chiSquaredTestForAssociation(wave_location);
- % Calculate the column sums
- colSums = sum(tbl);
- % Convert each value to a percentage of its respective column
- percentageDataColumn = (tbl ./ colSums) * 100;
- % Calculate the row sums
- rowSums = sum(tbl,2);
- % Convert each value to a percentage of its respective column
- percentageDataRow = (tbl ./ rowSums) * 100;
- % other features
- %combinedTable_NM(105,:) = [];
- clusterFeatures = table(idx, ...
- combinedTable_sorted.("Area(um2)"), ...
- combinedTable_sorted.Perimeter, ...
- combinedTable_sorted.Circularity, ...
- combinedTable_sorted.("Max dFF"), ...
- combinedTable_sorted.("dFF AUC"),...
- combinedTable_sorted.("Duration 10% to 10%"), ...
- combinedTable_sorted.("Number of Events"), ...
- 'VariableNames', {'Cluster', 'Area_um2', 'Perimeter', 'Circularity', 'Max_dFF', 'dFF AUC', 'Duration_10to10', 'Num_Events'});
- % Split data into two tables based on cluster assignment
- clusterFeatures_cluster1 = clusterFeatures(clusterFeatures.Cluster == 1, :);
- clusterFeatures_cluster2 = clusterFeatures(clusterFeatures.Cluster == 2, :);
- compareClusterFeatures(clusterFeatures, clusterFeatures_cluster1, clusterFeatures_cluster2);
- %number of events
- numberOfEvents_Cluster1 = clusterFeatures_cluster1(:,"Num_Events");
- totalEvents_Cluster1 = sum(numberOfEvents_Cluster1{:,:});
- %number of events in Hz
- numberOfEvents_Cluster1_Hz = table2cell(numberOfEvents_Cluster1);
- numberOfEvents_Cluster1_Hz = cell2mat(numberOfEvents_Cluster1_Hz);
- numberOfEvents_Cluster1_Hz = numberOfEvents_Cluster1_Hz / 900;
- numberOfEvents_Cluster1_Hz_new = numberOfEvents_Cluster1_Hz * 1000;
- %number of events
- numberOfEvents_Cluster2 = clusterFeatures_cluster2(:,"Num_Events");
- totalEvents_Cluster2 = sum(numberOfEvents_Cluster2{:,:});
- %number of events in Hz
- numberOfEvents_Cluster2_Hz = table2cell(numberOfEvents_Cluster2);
- numberOfEvents_Cluster2_Hz = cell2mat(numberOfEvents_Cluster2_Hz);
- numberOfEvents_Cluster2_Hz = numberOfEvents_Cluster2_Hz / 900;
- numberOfEvents_Cluster2_Hz_new = numberOfEvents_Cluster2_Hz * 1000;
- %%
- % Plot waves based on SNR (visual)
- figure;
- histogram(snr_ma);
- Q2 = prctile(snr_ma, 75);
- % Define threshold for high SNR
- snr_threshold = 22;
- % Find high SNR cells
- highSNRcells = snr_ma > snr_threshold;
- lowSNRcells = snr_ma < snr_threshold;
- % Get logical indices
- selectedCells_indices = find(highSNRcells);
- % Plot selected dFF traces
- set(0, 'DefaultFigureWindowStyle', 'docked');
- plot_selected_dFF_waves(combinedTable_NM, '', false, selectedCells_indices);
- % correlation SNR and event duration
- snr_duration = zeros(size(snr_ma,1), 2);
- for cellIdx = 1:size(snr_ma,1)
- snr_duration(cellIdx, :) = [snr_ma(cellIdx), combinedTable_NM{cellIdx, "Duration 10% to 10%"}];
- end
- %% Apply Savitzky-Golay filtering only for visualization, not for clustering.
- % Optimize Sgolay params - takes very long time to optimize both params
- poly_orders = 1:6;
- frame_sizes = 5:2:927;
- [best_poly_order, best_frame_size, best_snr, best_filtered_signals] = optimizeSgolayParams(dFF_all, poly_orders, frame_sizes);
- % Optimize only frame range
- poly_order = 3;
- frame_range = 5:2:927; % Must be odd values
- best_frame_sizes = optimizeFrameSize(dFF_all, poly_order, frame_range);
AQuA2_6_Waves_CSD.m at commit 1b99674, under GPL-3.0 · at the source
Overview
Abstract
The meninges, which envelop and protect the brain, host a dense network of resident macrophages with diverse roles in regulating homeostasis and neuroinflammation. Despite their importance, we have a limited understanding of their behavior in vivo. Many dynamic cellular functions of macrophages involve intracellular Ca2+ signaling. However, virtually nothing is known about the spatiotemporal Ca2+ dynamics of meningeal macrophages in vivo. We developed a chronic intravital two-photon imaging approach and related computational analysis tools to interrogate meningeal macrophage Ca2+ dynamics, at subcellular resolution, in a novel Pf4-Cre:Ai162 conditional GCaMP6s reporter mouse model. Using imaging in awake mice, we characterized Ca2+ activity in meningeal macrophages at steady state and in response to cortical spreading depolarization (CSD), an aberrant pro-inflammatory brain hyperexcitability event implicated in migraine, traumatic brain injury, and stroke. In homeostatic meninges, macrophages in the dural perivascular niche exhibited several Ca2+ dynamic features, including event duration and signal frequency spectrum, distinct from those localized to the interstitial, non-perivascular niche. Simultaneous tracking of macrophage Ca2+ dynamics and local vasomotion revealed a subset of dural perivascular macrophages whose activity was coupled to locomotion-driven diameter fluctuations of their associated vessels. Most perivascular and non-perivascular meningeal macrophages displayed propagating intracellular Ca2+ activity and synchronized intercellular Ca2+ elevations, potentially driven by extrinsic factors. In response to CSD, the majority of perivascular and non-perivascular meningeal macrophages showed a persistent decrease in Ca2+ activity, while a smaller subset displayed Ca2+ elevations. Mechanistically, calcitonin gene-related peptide receptor signaling mediated the increase but not the decrease in CSD-mediated Ca2+ signaling. Collectively, our results highlight a previously unknown diversity of Ca2+ dynamics in meningeal macrophages at steady state and in response to an aberrant brain hyperexcitability event linked to neuroinflammation.
Reproduced under the paper's license (CC BY), from the paper cited above.
Repositories
Its files are read in the Code ↔ Paper reader above, with 20 matches between paragraphs and lines of code.
levylabheadache/movieprocessing
d40d58fa17e4c81ce7cb3779ef141d7edada653e, 30 March 2023Availability: 1 check, the latest on 28 September 2026: the link answers
- 28 September 2026: the link answers
107 files
- AffineRepair.m, MATLAB, 191 lines
- AlignPlanes.m, MATLAB, 194 lines
- ApplyOptotuneWarp.m, MATLAB, 8 lines
- ApplyXYShiftsFBS.m, MATLAB, 26 lines
- ApplyZShiftInterpolateFB
S.m , MATLAB, 37 lines - Array2ij.m, MATLAB, 89 lines
- CatInterpZ.m, MATLAB, 135 lines
- ConcatenateExptRuns.m, MATLAB, 242 lines
- ConcatenateExptRuns_Test
.m , MATLAB, 61 lines - ConcatenateRunInfo.m, MATLAB, 66 lines
- ConcatenateRuns.m, MATLAB, 66 lines
- ConcatenateSinglePlane.m
, MATLAB, 86 lines - CorrectCatData.m, MATLAB, 116 lines
- CorrectData2D.m, MATLAB, 110 lines
- CorrectData3D.m, MATLAB, 123 lines
- CorrectDeformation.m, MATLAB, 147 lines
- CorrectExpt.m, MATLAB, 240 lines
- CropFrames.m, MATLAB, 7 lines
- DFT_rect.m, MATLAB, 29 lines
- DFT_reg.m, MATLAB, 17 lines
- DFT_reg_z_interp.m, MATLAB, 198 lines
- DFT_warp_2D.m, MATLAB, 84 lines
- DFT_warp_3D.m, MATLAB, 166 lines
- DefaultProcessingParams.
m , MATLAB, 70 lines - DeterminePMT.m, MATLAB, 32 lines
- DetermineReference.m, MATLAB, 64 lines
- DetermineXYShiftsFBS.m, MATLAB, 49 lines
- DewarpSbx.m, MATLAB, 113 lines
- EstimateZshift.m, MATLAB, 90 lines
- ExptInterpZ.m, MATLAB, 133 lines
- FileFinder.m, MATLAB, 89 lines
- FixSBX.m, MATLAB, 142 lines
- GenerateExptProjections.
m , MATLAB, 173 lines - GetDeformCat3D.m, MATLAB, 406 lines
- GetDimensions.m, MATLAB, 55 lines
- GetEdges.m, MATLAB, 91 lines
- GetOptotuneWarp.m, MATLAB, 128 lines
- GetOptotuneWarp_old.m, MATLAB, 134 lines
- GetRunInfo.m, MATLAB, 8 lines
- GetRunNumber.m, MATLAB, 3 lines
- GetSegParams.m, MATLAB, 14 lines
- GetTime.m, MATLAB, 14 lines
- InterpZ.m, MATLAB, 151 lines
- InterpolateZshift.m, MATLAB, 90 lines
- LoadSBXinfo.m, MATLAB, 82 lines
- LoadTransforms.m, MATLAB, 95 lines
- MakeCatSbxz.m, MATLAB, 42 lines
- MakeChunkLims.m, MATLAB, 36 lines
- MakeDeformPlot.m, MATLAB, 21 lines
- MakeInfoStruct.m, MATLAB, 128 lines
- MakeSbxDFT.m, MATLAB, 152 lines
- MakeSbxPartial.m, MATLAB, 68 lines
- MakeSbxZ.m, MATLAB, 32 lines
- MakeSbxZ_new.m, MATLAB, 37 lines
- MakeSbxZ_old.m, MATLAB, 33 lines
- MakeSbxreg.m, MATLAB, 87 lines
- MakeTifName.m, MATLAB, 19 lines
- MovingPercentile.m, MATLAB, 49 lines
- MultiStackReg_Fiji_affin
e.m , MATLAB, 71 lines - MultiStackReg_Fiji_rigid
.m , MATLAB, 75 lines - OptoAlign_rigid.m, MATLAB, 76 lines
- ParseDataTable.m, MATLAB, 159 lines
- ProcessScanboxData.m, MATLAB, 173 lines
- ProcessScanboxData_conca
tFirst.m , MATLAB, 145 lines - ProjectRawData.m, MATLAB, 20 lines
- ProjectionDemo.m, MATLAB, 35 lines
- RectifyStack.m, MATLAB, 38 lines
- RectifyStackDFT.m, MATLAB, 34 lines
- RegisterCat3D.m, MATLAB, 123 lines
- RegisterRun.m, MATLAB, 137 lines
- RegisterSBX.m, MATLAB, 378 lines
- RegisterSBX_old.m, MATLAB, 340 lines
- RunIJ.m, MATLAB, 102 lines
- RunImageJ.m, MATLAB, 105 lines
- SbxWriter.m, MATLAB, 82 lines
- SegmentCat3D.m, MATLAB, 267 lines
- ShowEdges.m, MATLAB, 42 lines
- UnpackSBX.m, MATLAB, 55 lines
- VisualizeSegmentation.m, MATLAB, 51 lines
- WriteSbxPlaneTif.m, MATLAB, 166 lines
- WriteSbxProjection.m, MATLAB, 150 lines
- WriteSbxVolumeTif.m, MATLAB, 150 lines
- WriteSbxZproj.m, MATLAB, 202 lines
- WriteSbxZproj_old.m, MATLAB, 183 lines
- WriteTiff.m, MATLAB, 36 lines
- binXY.m, MATLAB, 29 lines
- bin_mov_xyt.m, MATLAB, 85 lines
- dftregistration3D.m, MATLAB, 70 lines
- dftregistrationAlex.m, MATLAB, 203 lines
- downsampleWithAvg.m, MATLAB, 25 lines
- group_z_project.m, MATLAB, 16 lines
- imgGaussBlur.m, MATLAB, 19 lines
- implay2chan.m, MATLAB, 17 lines
- imresizen.m, MATLAB, 71 lines
- load_tiff.m, MATLAB, 26 lines
- load_tiff_folder.m, MATLAB, 44 lines
- load_tiff_nobar.m, MATLAB, 17 lines
- loadtiff.m, MATLAB, 156 lines
- naninterp.m, MATLAB, 4 lines
- rad2deg.m, MATLAB, 14 lines
- readSBX.m, MATLAB, 71 lines
- rigidAlignScrap.m, MATLAB, 84 lines
- saveastiff.m, MATLAB, 362 lines
- sort_nat.m, MATLAB, 95 lines
- write2chanTiff.m, MATLAB, 34 lines
- zproj_reg.m, MATLAB, 81 lines
- LICENSE, License, 674 lines
levylabheadache/locomotion
96fdaa6bc2364f55cfabc67cc4a168d89ec5fcbc, 29 January 2024Availability: 1 check, the latest on 28 September 2026: the link answers
- 28 September 2026: the link answers
18 files
- BinStillEpochs.m, MATLAB, 212 lines
- BoutEffect.m, MATLAB, 14 lines
- BoutEffectConfInt.m, MATLAB, 30 lines
- BoutEffectPval.m, MATLAB, 15 lines
- BoutResponse.m, MATLAB, 370 lines
- GetBoutData.m, MATLAB, 59 lines
- GetLocoData.m, MATLAB, 96 lines
- GetLocoState.m, MATLAB, 131 lines, 1 match
- GetMergedBoutData.m, MATLAB, 87 lines
- GetStillEpochs.m, MATLAB, 292 lines
- LocoBoutAnalysis.m, MATLAB, 120 lines
- PeriLoco.m, MATLAB, 120 lines
- PeriLoco3D.m, MATLAB, 131 lines
- PeriLoco3D_new.m, MATLAB, 140 lines
- TrainLocoHMM.m, MATLAB, 152 lines, 1 match
- TrainMouseLocoHMM.m, MATLAB, 47 lines
- WriteBoutMovies.m, MATLAB, 250 lines
- LICENSE, License, 674 lines
levylabheadache/Aqua2Processing
1b9967459c36796c74cc25ee7b93169afadaadfe, 6 May 2026Availability: 1 check, the latest on 28 September 2026: the link answers
- 28 September 2026: the link answers
127 files
- AQUA2_postAnalysis_corre
lation.m , MATLAB, 116 lines - AQUA2_postAnalysis_graph
s.m , MATLAB, 854 lines - AQUA2_postAnalysis_violi
nGraphs.m , MATLAB, 350 lines - AQUA2_postAnalysis_violi
nGraphs_fullCraniotomy_r , MATLAB, 95 linesed_vs_nonRed(NP).m - AQUA2_postAnalysis_violi
nGraphs_fullCraniotomy_r , MATLAB, 108 linesed_vs_nonRed(NP,NM).m - AQUA2_postAnalysis_violi
nGraphs_fullCraniotomy_v , MATLAB, 159 liness_thinBone.m - AQuA2_1_cellFeatures_sin
gleExpt.m , MATLAB, 343 lines - AQuA2_2_cellFeatures_CSD
.m , MATLAB, 438 lines - AQuA2_2_cellFeatures_bas
eline.m , MATLAB, 277 lines - AQuA2_3_eventPropagation
_singleExpt.m , MATLAB, 46 lines - AQuA2_4_eventPropagation
_multiExpt.m , MATLAB, 205 lines - AQuA2_5_cellNetwork_mult
iExpt_CSD.m , MATLAB, 620 lines, 1 match - AQuA2_5_cellNetwork_mult
iExpt_baseline.m , MATLAB, 549 lines, 1 match - AQuA2_5_cellNetwork_mult
iExpt_baseline_byCellTyp , MATLAB, 232 linese.m - AQuA2_5_cellNetwork_mult
iExpt_baseline_byCellTyp , MATLAB, 246 linese_usingDigraph.m - AQuA2_6_Waves.m, MATLAB, 216 lines, 1 match
- AQuA2_6_Waves_CSD.m, MATLAB, 689 lines, 3 matches
- AQuA2_7_Network.m, MATLAB, 126 lines
- AQuA2_8_CFU_projection.m
, MATLAB, 211 lines - AQuA2_CFU_combined_allFe
atures_perAnimal_231204. , MATLAB, 97 linesm - AQuA2_CFU_combined_dFFcu
rve_perCell.m , MATLAB, 40 lines - AQuA2_circularity.m, MATLAB, 6 lines
- AQuA2_getRisingTime_cell
Propagation.m , MATLAB, 73 lines - AQuA2_postAnalysis_PCA.m
, MATLAB, 184 lines - AQuA2_postAnalysis_clust
ering.m , MATLAB, 266 lines - AQuA2_postAnalysis_heatm
ap_dFF.m , MATLAB, 273 lines - AQuA2_postAnalysis_raste
rPlot.m , MATLAB, 226 lines - AQuA2_postAnalysis_tSNE.
m , MATLAB, 35 lines - AQuA2_waves_examples.m, MATLAB, 1 line
- CSD_others.m, MATLAB, 18 lines
- CSDparams.m, MATLAB, 70 lines
- Conditional probabilities_CSD.m, MATLAB, 85 lines
- Heatmap_OngoingActivity_
Subplots.m , MATLAB, 65 lines - PNG_to_PDF.m, MATLAB, 13 lines
- analyzeCellConnectivity.
m , MATLAB, 112 lines - autoCluster_dFF_PCA.m, MATLAB, 62 lines
- calculateEventMean.m, MATLAB, 41 lines
- calculateEventMedian.m, MATLAB, 43 lines
- calculateEventRate.m, MATLAB, 100 lines
- calculateEventSum.m, MATLAB, 41 lines
- calculateNetDirectionali
ty.m , MATLAB, 33 lines - categorize_waves.m, MATLAB, 73 lines
- cellPairsDistanceDistrib
ution.m , MATLAB, 35 lines - chi2gof_from_table.m, MATLAB, 26 lines
- chiSquareTest.m, MATLAB, 52 lines
- chiSquare_residuals.m, MATLAB, 51 lines, 1 match
- chiSquaredTestForAssocia
tion.m , MATLAB, 45 lines - chi_square_by_acuteRespo
nse.m , MATLAB, 34 lines - chi_square_by_chronicRes
ponse.m , MATLAB, 40 lines - chi_square_plot.m, MATLAB, 72 lines
- classifyAllCategories.m, MATLAB, 76 lines
- classifyEventRatesCSD2.m
, MATLAB, 130 lines, 1 match - clusterCa2Signals.m, MATLAB, 242 lines, 2 matches
- clusterCells.m, MATLAB, 96 lines
- clusterParams_CSD.m, MATLAB, 147 lines, 1 match
- clusterSNR.m, MATLAB, 142 lines
- clusterWaves_CSD_acute_c
hronic.m , MATLAB, 95 lines - clusterWaves_CSD_simple.
m , MATLAB, 63 lines - clusterWaves_baseline.m, MATLAB, 202 lines
- clusterWaves_eventCount6
_CSD.m , MATLAB, 99 lines - clusterWaves_eventRate6_
CSD.m , MATLAB, 94 lines, 1 match - clusterWaves_eventRate9_
CSD.m , MATLAB, 113 lines - cluster_dFF.m, MATLAB, 58 lines
- combineCellMaps.m, MATLAB, 50 lines
- compareBaselineRates.m, MATLAB, 27 lines
- compareClusterAssignment
s.m , MATLAB, 48 lines - compareClusterFeatures.m
, MATLAB, 87 lines - computeEventDurationCorr
elation.m , MATLAB, 46 lines - computePairwiseCenterDis
tances.m , MATLAB, 37 lines - computePairwiseDistances
.m , MATLAB, 91 lines - computeSNR.m, MATLAB, 123 lines
- computeShortestDistances
.m , MATLAB, 46 lines - compute_Clusterwise_prob
abilities.m , MATLAB, 180 lines - correlationBetweenCellPa
irsAndEdge.m , MATLAB, 32 lines - correlationBetweenNumber
ofEventsAndOUTdegreeNode , MATLAB, 34 lines.m - createClassificationTabl
e.m , MATLAB, 32 lines - createHeatmap.m, MATLAB, 22 lines
- createParameterCSV.m, MATLAB, 19 lines
- eventNetwork_cellMap.m, MATLAB, 64 lines
- eventRateCSDPie.m, MATLAB, 40 lines
- eventsCSDphases.m, MATLAB, 92 lines
- extractPercentageConnect
edAll.m , MATLAB, 27 lines - extractStartingFramesByC
ell.m , MATLAB, 38 lines - fillMissingCellRows.m, MATLAB, 33 lines
- findOptimalClusters.m, MATLAB, 54 lines
- getEdgeDistances.m, MATLAB, 84 lines
- greenChannel_dataAnalysi
s.m , MATLAB, 80 lines - loadAnalysisData.m, MATLAB, 62 lines
- network_byCellType.m, MATLAB, 129 lines
- optimizeFrameSize.m, MATLAB, 129 lines
- optimizeSgolay.m, MATLAB, 78 lines
- optimizeSgolayParams.m, MATLAB, 109 lines
- plotCSDBoxplots.m, MATLAB, 39 lines
- plotCellDistanceNetwork.
m , MATLAB, 270 lines - plotChi2Residuals.m, MATLAB, 64 lines
- plotCluster6Distribution
.m , MATLAB, 89 lines - plotClusterDistributionB
yCellType.m , MATLAB, 54 lines - plotClusterDistributionB
yFOV.m , MATLAB, 93 lines - plotClusterHeatmap_FOVno
rmalized.m , MATLAB, 79 lines - plotClusterHeatmap_zscor
e.m , MATLAB, 133 lines - plotConditionalProbabili
ties.m , MATLAB, 112 lines - plotEdgesFromOrigin.m, MATLAB, 54 lines
- plotFFT.m, MATLAB, 28 lines, 1 match
- plotFFT_all.m, MATLAB, 38 lines
- plotFFT_clusters.m, MATLAB, 186 lines
- plotFOVDistributionByClu
ster.m , MATLAB, 71 lines - plotFilteredSignal.m, MATLAB, 26 lines
- plotNodeConnectivityGrap
h.m , MATLAB, 141 lines - plotRasterByCluster.m, MATLAB, 134 lines, 1 match
- plotRasterByCluster_5row
sPerCluster.m , MATLAB, 57 lines - plotSelectedWaves_togeth
er.m , MATLAB, 47 lines - plotStackedDirectionGrou
ps.m , MATLAB, 47 lines - plotStdResiduals.m, MATLAB, 35 lines
- plotSynchronizedEvents.m
, MATLAB, 493 lines - plot_dFF_waves.m, MATLAB, 47 lines
- plot_selected_dFF_waves.
m , MATLAB, 49 lines - processAndClassify.m, MATLAB, 89 lines
- processCSDphases.m, MATLAB, 84 lines
- propagationCellMap.m, MATLAB, 65 lines
- saveConnectedNetworks.m, MATLAB, 52 lines
- savePDF.m, MATLAB, 33 lines
- savePNG.m, MATLAB, 24 lines
- sortFileNames.m, MATLAB, 37 lines
- sortFileNamesPf4Ai162.m, MATLAB, 33 lines
- sumEdgeVectors.m, MATLAB, 90 lines
- LICENSE, License, 674 lines
- README.md, Text, 6 lines
levylabheadache/vasculature
e619456255a0eff1026cb340a5a4e21ff8f86dc8, 30 March 2023Availability: 1 check, the latest on 28 September 2026: the link answers
- 28 September 2026: the link answers
25 files
- AnalyzeVasculature.m, MATLAB, 43 lines
- BatchVasc.m, MATLAB, 47 lines
- BatchVascNew.m, MATLAB, 56 lines
- BatchVasculature.m, MATLAB, 132 lines
- CalcFWHM.m, MATLAB, 89 lines
- CalculateDiameter.m, MATLAB, 160 lines
- DiamCalcSurfaceVesselExa
mple.m , MATLAB, 549 lines - DiamCalcSurfaceVessel_te
st.m , MATLAB, 205 lines - DuraVsPiaExample.m, MATLAB, 117 lines
- EstimateVesselDiameter.m
, MATLAB, 168 lines - FWHM_MovieProjection.m, MATLAB, 24 lines
- GLM_LocoDeformDiam.m, MATLAB, 117 lines
- GLM_LocoDiam.m, MATLAB, 688 lines
- GLM_LocoDiamDeform.m, MATLAB, 272 lines
- GetDiameterFromMovie.m, MATLAB, 18 lines
- GetVascExpt.m, MATLAB, 51 lines
- GetVesselDiameter.m, MATLAB, 26 lines
- GetVesselProfile.m, MATLAB, 69 lines, 1 match
- GetVesselProfile_test.m, MATLAB, 26 lines
- MakeVesselROI.m, MATLAB, 51 lines
- Pial_Vasodilation.m, MATLAB, 1 line
- RegisterVascData.m, MATLAB, 152 lines
- RemoveMotion.m, MATLAB, 37 lines
- RemoveVesselMotion.m, MATLAB, 46 lines
- SegmentVasculature.m, MATLAB, 90 lines
levylabheadache/GeneralLinearModel_Macrophages
1bb746e859b3bde8eeef4e85a29494eadee14667, 6 May 2026Availability: 1 check, the latest on 28 September 2026: the link answers
- 28 September 2026: the link answers
11 files
- GLM_1_LocoDiam.m, MATLAB, 312 lines
- GLM_2_DiamFluorescence.m
, MATLAB, 236 lines, 1 match - GLM_LocoDiamFluorescence
.m , MATLAB, 539 lines - GLM_LocoFluorescence.m, MATLAB, 389 lines, 1 match
- GLM_velocityDiam.m, MATLAB, 849 lines
- plotGLM_LocoDiam_baselin
e.m , MATLAB, 323 lines - plotGLM_diamFluorescence
_baseline.m , MATLAB, 494 lines - plotGLM_locoDiamFluor.m, MATLAB, 359 lines, 1 match
- plotGLM_locoDiamFluor_pa
per.m , MATLAB, 96 lines - LICENSE, License, 674 lines
- README.md, Text, 6 lines
The paper's code and data availability statement is in the Data section.
Tracing map
Proposed by the machine: these links were found in the paper and verified at the source, without human review. The map will receive a Zenodo DOI once one of the paper's authors has validated it with their ORCID.
What the map holds:
- 5 repositories of the authors' code, each at its verified commit, with its license and how the link was found in the paper;
- 282 scripts, each with its path and the digest of its content;
- 20 matches between paragraphs of the paper and lines of the code (method lexical-v1);
- neither the text of the paper nor the code itself.
Its JSON (tracing-map.json) is deposited on Zenodo with its DOI once the map is validated.
Data
No dataset and no data link were found in the paper.
Data availability
All data needed to evaluate the conclusions in the paper are present in the manuscript. The code used for analyzing the data in this study was deposited in the Levy Lab GitHub account. Code for movie processing is available at GitHub (https://
Reproduced under the paper's license (CC BY), from the paper cited above.
Versions
The history of this record: each version stored by the harvester or made by a correction of its authors or of the maintainers of its code, and what changed in its facts. The texts of the paper (its abstract, its availability statements) are not part of it; versions that changed only those are not listed.
Version 1, 28 September 2026: the first record
Recorded: type, language, journal, volume, pages, dates, 4 authors, 8 keywords, 9 MeSH terms, 1 funder, 71 references.
Cite
This paper
Carneiro-Nascimento, S., Wei, C., Gutterman, A., & Levy, D. (2026). Intravital calcium imaging of meningeal macrophages reveals niche-specific dynamics and aberrant responses to brain hyperexcitability. eLife, 15, RP109888. https://
BibTeX
@article{carneironascime
author = {Carneiro-Nascimento, Simone and Wei, Chao and Gutterman, Anna and Levy, Dan},
title = {{Intravital calcium imaging of meningeal macrophages reveals niche-specific dynamics and aberrant responses to brain hyperexcitability}},
journal = {eLife},
year = {2026},
month = may,
volume = {15},
pages = {RP109888},
publisher = {eLife Sciences Publications, Ltd},
issn = {2050-084X},
doi = {10.7554/
url = {https://
pmid = {42126091},
pmcid = {PMC13171100}
}
RIS
TY - JOUR
AU - Carneiro-Nascimento, Simone
AU - Wei, Chao
AU - Gutterman, Anna
AU - Levy, Dan
TI - Intravital calcium imaging of meningeal macrophages reveals niche-specific dynamics and aberrant responses to brain hyperexcitability
T2 - eLife
J2 - Elife
PY - 2026
DA - 2026/
VL - 15
SP - RP109888
SN - 2050-084X
PB - eLife Sciences Publications, Ltd
DO - 10.7554/
UR - https://
LA - en
ER -
CSL-JSON
{
"id": "10.7554/
"type": "article-journal",
"title": "Intravital calcium imaging of meningeal macrophages reveals niche-specific dynamics and aberrant responses to brain hyperexcitability",
"container-title": "eLife",
"author": [
{
"family": "Carneiro-Nascimento",
"given": "Simone"
},
{
"family": "Wei",
"given": "Chao"
},
{
"family": "Gutterman",
"given": "Anna"
},
{
"family": "Levy",
"given": "Dan"
}
],
"container-title-short":
"volume": "15",
"page": "RP109888",
"DOI": "10.7554/
"PMID": "42126091",
"PMCID": "PMC13171100",
"ISSN": "2050-084X",
"publisher": "eLife Sciences Publications, Ltd",
"URL": "https://
"language": "en",
"issued": {
"date-parts": [
[
2026,
5,
13
]
]
}
}
The tracing map gets a citation of its own once an author has validated it and it has a DOI.
Similar papers
The papers with a page that share the most with this one: the tools found in their code, their categories, datasets, cited references and authors, the rarest counting most.
- [1] doi:10.1016/j.celrep.2026.117411
- Enhancing the specificity of microglia genetic targeting using a CSF1R inhibitor.Journal: Cell reportsIn common: mouse, cellular / molecular, 5 references
- [2] doi:10.1016/j.crmeth.2026.101472 [code]
- Rapid neuronal labeling and functional imaging in the developing mouse brain with AAV-PHP.eB.Journal: Cell reports methodsIn common: Optimization Toolbox, Image Processing Toolbox, Signal Processing Toolbox, 1 other tool, optical imaging (calcium, voltage, 2-photon), histology / microscopy, mouse
- [3] doi:10.1038/s41592-026-03066-1 [code]
- A multimodal adaptive optical microscope for in vivo imaging from molecules to organisms.Journal: Nature methodsIn common: Optimization Toolbox, Image Processing Toolbox, Signal Processing Toolbox, 1 other tool, optical imaging (calcium, voltage, 2-photon), histology / microscopy, mouse
- [4] doi:10.1093/brain/awag080 [code]
- Early glymphatic failure in AppNL-F knock-in mice is linked to parenchymal border macrophages loss.Journal: Brain : a journal of neurologyIn common: mouse, cellular / molecular, 4 references
- [5] doi:10.1186/s12974-026-03794-3
- Single-cell omics and flow cytometry identify distinct immune states of dural and brain-infiltrating IL-17-producing γδ T cells after experimental stroke.Journal: Journal of neuroinflammationIn common: mouse, cellular / molecular, 4 references
- [6] doi:10.3390/biomedicines14081670 [code]
- Limited Detectability of Network Functional Alterations in a Tauopathy Model Using Mouse Primary Cortical Cultures.Journal: BiomedicinesIn common: Optimization Toolbox, Image Processing Toolbox, Signal Processing Toolbox, 1 other tool, optical imaging (calcium, voltage, 2-photon), mouse
- [7] doi:10.1038/s41592-026-03154-2 [code]
- Simultaneous single-cell calcium imaging of neuronal population activity and brain-wide BOLD fMRI.Journal: Nature methodsIn common: Image Processing Toolbox, Signal Processing Toolbox, Statistics and Machine Learning Toolbox, optical imaging (calcium, voltage, 2-photon), mouse, 1 reference
- [8] doi:10.1016/j.isci.2026.117187 [code]
- Functional and structural characterization of dendritic spine pathology in a mouse model of tauopathy.Journal: iScienceIn common: Optimization Toolbox, Image Processing Toolbox, Signal Processing Toolbox, 1 other tool, histology / microscopy, mouse
- [9] doi:10.1038/s41593-026-02358-1 [code]
- Cerebral venous blood flow regulates intracerebral pressure and brain clearance via meningeal lymphatic vessels.Journal: Nature neuroscienceIn common: mouse, 4 references
- [10] doi:10.1002/hbm.70602 [code]
- Neuroimaging Correlates of Post-Stroke Pain After Ischemic Stroke: Secondary Analysis of the INSPiRE-TMS Trial.Journal: Human brain mappingIn common: Optimization Toolbox, Image Processing Toolbox, Signal Processing Toolbox, 1 other tool, pain
Contribute
The authors of this paper can claim it, correct its record and validate its tracing map, and the maintainers of its code (its owner, or a public member of its organization) correct what it says of their repository; anyone signed in can ask for its removal. Every request goes to OSCR's own machine, which answers it; your account page follows them.
Sign in with ORCID to claim this paper as one of its authors, correct its record or validate its tracing map: when the paper's metadata lists your ORCID iD, you are recognized at once. Maintainers of its code: sign in with GitHub, then claim the repository on your account page.
Claim this paper
Correct its record
Say what each link of this record is, remove the ones that are not the paper's, add the ones that are missing. The correction becomes a new version of the record, in its Versions section.
Validate its tracing map
You validate the map as this page shows it: 5 repositories of the authors' code, each at its verified commit and with its license, 282 scripts, and 20 matches between paragraphs and code (see the Code and Map sections). It then receives a DOI on Zenodo, with you (your ORCID iD) and OSCR as its creators; the code itself is not deposited.
The map's fingerprint: sha256:c38764b6e036442b…
Add the badge to its README
The badge links the code to this page. Copy one of these into the README of the paper's code: only you decide where it goes, and nothing is changed for you.
Markdown
[, paste the snippet at the top, then “Commit changes…” and, to review it first, “Create a new branch and start a pull request”. You open the pull request; OSCR asks for no permission.
Request its removal
To ask OSCR to remove this record, the copies of its authors' scripts or its tracing map, use the removal request page: signed in, you say who you are, what to remove and why, then review and confirm the request. Published rules decide every request (how).
Discussion, reproductions, activity
Discussion: questions and error reports about this paper and its code, from signed-in readers and its authors. It opens with sign-in.
Reproductions: reports from readers who ran the authors' code: what they reproduced, with which environment, commit and data. It opens with sign-in.
Activity: what happens around this paper: new versions of its record, its map's validation, discussions and reproductions. It opens with sign-in.
