Skip to content

Commit

Permalink
Match BCrating / braak / cerad info on the sce_pseudo objects on the …
Browse files Browse the repository at this point in the history
…spatialLIBD apps
  • Loading branch information
lcolladotor committed Mar 17, 2023
1 parent a7b322f commit 4336985
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
4 changes: 4 additions & 0 deletions code/05_deploy_app_wholegenome/app.R
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,10 @@ load(file.path(dir_rdata, "Visium_IF_AD_modeling_results.Rdata"),
sce_pseudo <-
readRDS(file.path(dir_rdata, "sce_pseudo_pathology_wholegenome.rds"))

## Change Braak info based on latest information from LIBD pathology
sce_pseudo$BCrating <- NULL ## This variable was removed from the phenotype table
sce_pseudo$braak <- c("Br3854" = "Stage VI", "Br3873" = "Stage V", "Br3880" = "Stage VI", "Br3874" = "Stage IV")[sce_pseudo$subject]
sce_pseudo$cerad <- c("Br3854" = "Frequent", "Br3873" = "Frequent", "Br3880" = "Frequent", "Br3874" = "None")[sce_pseudo$subject]

## For sig_genes_extract_all() to work
sce_pseudo$spatialLIBD <- sce_pseudo$path_groups
Expand Down
5 changes: 5 additions & 0 deletions code/06_deploy_app_targeted/app.R
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,11 @@ load(file.path(dir_rdata, "Visium_IF_AD_modeling_results.Rdata"),
sce_pseudo <-
readRDS(file.path(dir_rdata, "sce_pseudo_pathology_targeted.rds"))

## Change Braak info based on latest information from LIBD pathology
sce_pseudo$BCrating <- NULL ## This variable was removed from the phenotype table
sce_pseudo$braak <- c("Br3854" = "Stage VI", "Br3873" = "Stage V", "Br3880" = "Stage VI", "Br3874" = "Stage IV")[sce_pseudo$subject]
sce_pseudo$cerad <- c("Br3854" = "Frequent", "Br3873" = "Frequent", "Br3880" = "Frequent", "Br3874" = "None")[sce_pseudo$subject]

## For sig_genes_extract_all() to work
sce_pseudo$spatialLIBD <- sce_pseudo$path_groups
sig_genes <- sig_genes_extract_all(
Expand Down

0 comments on commit 4336985

Please sign in to comment.