theislab / txsim

3 stars 0 forks source link

add cell type proportion metrics #87

Closed RhineCloud closed 8 months ago

RhineCloud commented 8 months ago

Changes proposed in this pull request:

LouisK92 commented 8 months ago

I adjusted the computation for the abs scores, was meant to be very similar as for pos and neg scores.

Also I didn't run into warnings from the line that you in a with statement:

    with pd.option_context("mode.chained_assignment", None):
        df_cells["sp_minus_sc"] = df_cells[obs_key].map(df_props["sp_minus_sc"]).astype(float)

Therefore took the with ... out - what was the reason for it?

RhineCloud commented 8 months ago

I kept getting SettingWithCopyWarnings even after multiple variations of using different indexing methods, including loc as was suggested in the warning, but maybe it worked without setting off the warning after all?

LouisK92 commented 8 months ago

I see, yea seems like it somehow works so far at least when I tried.. ^^ Let's keep it like this for now.