ShobiStassen / PARC

MIT License
41 stars 11 forks source link

Questions on using PARC for identifying plasma cells #21

Open nilaj-c opened 2 years ago

nilaj-c commented 2 years ago

Hi, I am trying to use PARC for Flow Cytometry and I want to identify Plasma cells which is usually done by manually gating on CD38 and CD138. The gate identifies the high CD38 and CD138 population (upper right corner on the 2-d CD38 vs Cd138 graph). To replicate the same process in PARC is the following the proper method:

X contains CD38, CD138 and 12 other antigen columns

Parc1 = parc.PARC(X, jac_std_global=0.15, random_seed = 2, small_pop = 20) Parc1.run_PARC() parc_labels = Parc1.labels

Attach a column called "Cluster" to identify which cell belongs to which cluster

df['cluster'] = pd.Series(Parc1.labels, index=df.index)

Find which cluster has the max value for the sum

sum_df = df.groupby(['cluster'])[["CD38", "CD138"]].sum().sum(axis=1) sum_df.sort_values(ascending=False)

ShobiStassen commented 2 years ago

@nilaj-c Hi, thanks for trying out PARC. I'm just seeing your message and wondering whether this approach ended up working for you?