diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index b2acce8..1561d06 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -24,11 +24,14 @@ repos: - id: detect-private-key - id: check-ast - id: end-of-file-fixer + exclude: ^data/data.fcs$ - id: mixed-line-ending args: [--fix=lf] - exclude: .fcs + exclude: ^data/data.fcs$ - id: trailing-whitespace + exclude: ^data/data.fcs$ - id: check-case-conflict + exclude: ^data/data.fcs$ # Check that there are no merge conflicts (could be generated by template sync) - id: check-merge-conflict args: [--assume-in-merge] diff --git a/data/data.fcs b/data/data.fcs index 42e6ca5..cb06a7f 100644 Binary files a/data/data.fcs and b/data/data.fcs differ diff --git a/scripts/process_fcs.ipynb b/scripts/process_fcs.ipynb index d2f2b2d..d7a8097 100644 --- a/scripts/process_fcs.ipynb +++ b/scripts/process_fcs.ipynb @@ -120,7 +120,8 @@ "}\n", "new_adata.obs[\"cell_type\"] = new_adata.obs[\"OmiqFileIndex\"].map(cell_type_mapping).astype(\"category\")\n", "new_adata.obs[\"patient\"] = new_adata.obs[\"OmiqFileIndex\"].map(patient_annotation).astype(\"category\")\n", - "new_adata.obs[\"cell_type_patient\"] = new_adata.obs[\"OmiqFileIndex\"].map(cell_type_patient_mapping).astype(\"category\")" + "new_adata.obs[\"cell_type_patient\"] = new_adata.obs[\"OmiqFileIndex\"].map(cell_type_patient_mapping).astype(\"category\")\n", + "new_adata.uns[\"cell_type_patient_color\"] = [\"red\", \"gray\", \"green\"]" ] }, { @@ -153,7 +154,7 @@ }, { "cell_type": "code", - "execution_count": 10, + "execution_count": 8, "metadata": {}, "outputs": [], "source": [ @@ -165,7 +166,7 @@ }, { "cell_type": "code", - "execution_count": 12, + "execution_count": 9, "metadata": {}, "outputs": [], "source": [ diff --git a/scripts/vitessce.ipynb b/scripts/vitessce.ipynb index 204ddcd..9031156 100644 --- a/scripts/vitessce.ipynb +++ b/scripts/vitessce.ipynb @@ -25,7 +25,7 @@ }, { "cell_type": "code", - "execution_count": null, + "execution_count": 1, "metadata": {}, "outputs": [], "source": [ @@ -49,7 +49,7 @@ }, { "cell_type": "code", - "execution_count": null, + "execution_count": 2, "metadata": {}, "outputs": [], "source": [ @@ -58,7 +58,7 @@ }, { "cell_type": "code", - "execution_count": null, + "execution_count": 3, "metadata": {}, "outputs": [], "source": [ @@ -84,7 +84,7 @@ }, { "cell_type": "code", - "execution_count": null, + "execution_count": 4, "metadata": {}, "outputs": [], "source": [ @@ -106,12 +106,30 @@ }, { "cell_type": "code", - "execution_count": null, + "execution_count": 5, "metadata": {}, - "outputs": [], + "outputs": [ + { + "data": { + "text/plain": [ + "'http://vitessce.io/#?theme=light&url=data:,%7B%22version%22%3A+%221.0.15%22%2C+%22name%22%3A+%22Science+Under+the+Stars%22%2C+%22description%22%3A+%22The+Dataset+for+the+event%22%2C+%22datasets%22%3A+%5B%7B%22uid%22%3A+%22A%22%2C+%22name%22%3A+%22Cancer_Patient%22%2C+%22files%22%3A+%5B%7B%22fileType%22%3A+%22anndata.zarr%22%2C+%22url%22%3A+%22http%3A%2F%2Flocalhost%3A8000%2FA%2F0%2F1d14fbfd-9d89-4f2d-98be-251ec9bee197.adata.zarr%22%2C+%22options%22%3A+%7B%22obsEmbedding%22%3A+%5B%7B%22path%22%3A+%22obsm%2FX_umap_2D%22%2C+%22dims%22%3A+%5B0%2C+1%5D%2C+%22embeddingType%22%3A+%22UMAP%22%7D%5D%2C+%22obsSets%22%3A+%5B%7B%22name%22%3A+%22Cell+Type%22%2C+%22path%22%3A+%22obs%2Fcell_type_patient%22%7D%5D%2C+%22obsFeatureMatrix%22%3A+%7B%22path%22%3A+%22X%22%7D%2C+%22featureLabels%22%3A+%7B%22path%22%3A+%22marker%22%7D%7D%2C+%22coordinationValues%22%3A+%7B%22obsType%22%3A+%22cell%22%2C+%22featureType%22%3A+%22gene%22%2C+%22featureValueType%22%3A+%22expression%22%7D%7D%5D%7D%5D%2C+%22coordinationSpace%22%3A+%7B%22dataset%22%3A+%7B%22A%22%3A+%22A%22%7D%2C+%22embeddingType%22%3A+%7B%22A%22%3A+%22UMAP%22%7D%7D%2C+%22layout%22%3A+%5B%7B%22component%22%3A+%22scatterplot%22%2C+%22coordinationScopes%22%3A+%7B%22dataset%22%3A+%22A%22%2C+%22embeddingType%22%3A+%22A%22%7D%2C+%22x%22%3A+0.0%2C+%22y%22%3A+0.0%2C+%22w%22%3A+6.0%2C+%22h%22%3A+6.0%7D%2C+%7B%22component%22%3A+%22obsSets%22%2C+%22coordinationScopes%22%3A+%7B%22dataset%22%3A+%22A%22%7D%2C+%22x%22%3A+6.0%2C+%22y%22%3A+0.0%2C+%22w%22%3A+6.0%2C+%22h%22%3A+3.0%7D%2C+%7B%22component%22%3A+%22featureList%22%2C+%22coordinationScopes%22%3A+%7B%22dataset%22%3A+%22A%22%7D%2C+%22x%22%3A+6.0%2C+%22y%22%3A+3.0%2C+%22w%22%3A+6.0%2C+%22h%22%3A+3.0%7D%2C+%7B%22component%22%3A+%22heatmap%22%2C+%22coordinationScopes%22%3A+%7B%22dataset%22%3A+%22A%22%7D%2C+%22x%22%3A+0.0%2C+%22y%22%3A+6.0%2C+%22w%22%3A+6.0%2C+%22h%22%3A+6.0%7D%2C+%7B%22component%22%3A+%22obsSetSizes%22%2C+%22coordinationScopes%22%3A+%7B%22dataset%22%3A+%22A%22%7D%2C+%22x%22%3A+6.0%2C+%22y%22%3A+6.0%2C+%22w%22%3A+6.0%2C+%22h%22%3A+6.0%7D%5D%2C+%22initStrategy%22%3A+%22auto%22%7D'" + ] + }, + "execution_count": 5, + "metadata": {}, + "output_type": "execute_result" + } + ], "source": [ "vc.web_app()" ] + }, + { + "cell_type": "code", + "execution_count": null, + "metadata": {}, + "outputs": [], + "source": [] } ], "metadata": {