Skip to content

Instantly share code, notes, and snippets.

@FloWuenne
Created March 17, 2018 15:45
Show Gist options
  • Select an option

  • Save FloWuenne/c4ab50836d577bbd32886959fd1f8f09 to your computer and use it in GitHub Desktop.

Select an option

Save FloWuenne/c4ab50836d577bbd32886959fd1f8f09 to your computer and use it in GitHub Desktop.
Quick testing of CIDR implementation
```{r}
## Read in some test data
colorectal <- readRDS("D:/Studies_PhD/Single_Cell_data/colorectal_cancer_Li_et_al_2017_SCESet.rds")
```
```{r}
sData <- scDataConstructor(as.matrix(colorectal))
sData <- determineDropoutCandidates(sData)
#sData <- wThreshold(sData)
#sData <- scDissim(sData)
#>
#sData <- scPCA(sData)
#sData <- nPC(sData)
#nCluster(sData)
#sData <- scCluster(sData)
#>
## Two dimensional visualization: different colors denote different cell types,
## while different plotting symbols denote the clusters output by cidr.
plot(sData@PC[,c(1,2)], col=sData@clusters,
main="CIDR", xlab="PC1", ylab="PC2")
ggplot(as.data.frame(sData@PC),aes(Axis.1,Axis.2)) +
geom_point()
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment