HIV Flow Cytometry

Author

Lindsay N Hayes

Published

January 21, 2025

About the Data

Analysis of FACS data from cells derived from 5-6 mL of cerebrospinal fluid (CSF) or 1-2 million peripheral blood cells from the same individuals. All subjects were virally-suppressed people with HIV. CSF-derived cells were processed fresh. PBMCs were analyzed from frozen aliquots.

Load the Data

library(ggplot2)
library(cowplot)
library(tidyverse)

data <- read.csv("20220817_02_STATS.csv", stringsAsFactors = TRUE)
CSF <- data %>% filter(Type == "CSF")
PBMC <- data %>% filter(Type == "PBMC")
data[,3:4]

Plots

ggplot(data, aes(x = Type, y = perc.myel.P2RY12, fill = Type)) + geom_boxplot() + geom_point(size = 2) + theme_cowplot() + scale_fill_manual(values = c("cornflowerblue", "firebrick2")) + ylab("% of myeloid cells \n P2RY12+") + ylim(0,100) + geom_point(aes(color = Sample)) + scale_colour_grey() + theme(legend.position="none")

ggplot(data, aes(x = Type, y = perc.myel.CD14, fill = Type)) + geom_boxplot() + geom_point(size = 2) + theme_cowplot() + scale_fill_manual(values = c("cornflowerblue", "firebrick2")) + ylab("% of myeloid cells \n CD14+") + ylim(0,100) + geom_point(aes(color = Sample)) + scale_colour_grey() + theme(legend.position="none")

ggplot(data, aes(x = Type, y = `perc.myel.CD14.CD16.`, fill = Type)) + geom_boxplot() + geom_point(size = 2) + theme_cowplot() + scale_fill_manual(values = c("cornflowerblue", "firebrick2")) + ylab("% of myeloid cells \n CD14+ & CD16+") + ylim(0,100) + geom_point(aes(color = Sample)) + scale_colour_grey() + theme(legend.position="none")

ggplot(data, aes(x = Type, y = perc.myel.CD11B, fill = Type)) + geom_boxplot() + geom_point(size = 2) + theme_cowplot() + scale_fill_manual(values = c("cornflowerblue", "firebrick2")) + ylab("% of myeloid cells \n CD11b+") + ylim(0,100) + geom_point(aes(color = Sample)) + scale_colour_grey() + theme(legend.position="none")

Statistics

paired T-test between PBMC vs CSF

% P2RY12

a <- data %>% filter(Type == "CSF") %>% mutate(pval = shapiro.test(perc.myel.P2RY12)$p.value)
b <- data %>% filter(Type == "PBMC") %>% mutate(pval = shapiro.test(perc.myel.P2RY12)$p.value)
tmp=rbind(a$pval[1], b$pval[1])
rownames(tmp)=c("CSF","PBMC")
colnames(tmp)=c("Shapiro Test for Normality")
round(tmp,2)
rm(a,b,tmp)

var.test(CSF$perc.myel.P2RY12, PBMC$perc.myel.P2RY12)
t.test(CSF$perc.myel.P2RY12, PBMC$perc.myel.P2RY12, paired = TRUE, var.equal = TRUE)

data %>% select(c(1:3,8)) %>% group_by(Type) %>% 
  summarise(mean = mean(perc.myel.P2RY12),
            sem = sd(perc.myel.P2RY12) / sqrt(n()),
            lower = (mean - sem),
            upper = (mean + sem))

paired T-test between PBMC vs CSF

% CD14

a <- data %>% filter(Type == "CSF") %>% mutate(pval = shapiro.test(perc.myel.CD14)$p.value)
b <- data %>% filter(Type == "PBMC") %>% mutate(pval = shapiro.test(perc.myel.CD14)$p.value)
tmp=rbind(a$pval[1], b$pval[1])
rownames(tmp)=c("CSF","PBMC")
colnames(tmp)=c("Shapiro Test for Normality")
round(tmp,2)
rm(a,b,tmp)

var.test(CSF$perc.myel.CD14, PBMC$perc.myel.CD14)
t.test(CSF$perc.myel.CD14, PBMC$perc.myel.CD14, paired = TRUE, var.equal = FALSE)

data %>% select(c(1:3,11)) %>% group_by(Type) %>% 
  summarise(mean = mean(perc.myel.CD14),
            sem = sd(perc.myel.CD14) / sqrt(n()),
            lower = (mean - sem),
            upper = (mean + sem))

paired T-test between PBMC vs CSF

% CD14 & CD16

a <- data %>% filter(Type == "CSF") %>% mutate(pval = shapiro.test(perc.myel.CD14.CD16.)$p.value)
b <- data %>% filter(Type == "PBMC") %>% mutate(pval = shapiro.test(perc.myel.CD14.CD16.)$p.value)
tmp=rbind(a$pval[1], b$pval[1])
rownames(tmp)=c("CSF","PBMC")
colnames(tmp)=c("Shapiro Test for Normality")
round(tmp,2)
rm(a,b,tmp)

var.test(CSF$perc.myel.CD14.CD16., PBMC$perc.myel.CD14.CD16.)
t.test(CSF$perc.myel.CD14.CD16., PBMC$perc.myel.CD14.CD16., paired = TRUE, var.equal = FALSE)

data %>% select(c(1:3,10)) %>% group_by(Type) %>% 
  summarise(mean = mean(perc.myel.CD14.CD16.),
            sem = sd(perc.myel.CD14.CD16.) / sqrt(n()),
            lower = (mean - sem),
            upper = (mean + sem))

Session Info

sessionInfo()