Skip to content
Snippets Groups Projects
Commit 0fc3462b authored by Gervaise Henry's avatar Gervaise Henry :cowboy:
Browse files

Sllow Epi/St SubClust Merge to have different resolutions

parent b636f3ff
No related merge requests found
......@@ -8,10 +8,8 @@ option_list=list(
make_option("--p",action="store",default="Pr",type='character',help="Project Name"),
make_option("--g",action="store",default="ALL",type='character',help="Group To Analyze"),
make_option("--st",action="store",default=TRUE,type='logical',help="Analyze Data With Stress Pops Removed?"),
make_option("--r",action="store",default=0.1,type='numeric',help="Resolution"),
make_option("--e",action="store",default="dws",type='character',help="ID for Epi"),
make_option("--s",action="store",default="go",type='character',help="ID for St"),
make_option("--u",action="store",default="go",type='character',help="ID for UK")
make_option("--s",action="store",default="go",type='character',help="ID for St")
)
opt=parse_args(OptionParser(option_list=option_list))
rm(option_list)
......@@ -45,10 +43,10 @@ sc10x.Group <- SetAllIdent(object=sc10x.Group,id="Lineage")
Epi.cell <- names(sc10x.Group@ident[sc10x.Group@ident=="Epi"])
St.cell <- c(names(sc10x.Group@ident[sc10x.Group@ident=="St"]),names(sc10x.Group@ident[sc10x.Group@ident=="?"]))
sc10x.Group <- SetIdent(object=sc10x.Group,cells.use=Epi.cell,ident.use=eval(parse(text=paste0("sc10x.Group@meta.data$Epi.res",opt$r,"[sc10x.Group@ident=='Epi']"))))
sc10x.Group <- SetIdent(object=sc10x.Group,cells.use=St.cell,ident.use=eval(parse(text=paste0("sc10x.Group@meta.data$St.res",opt$r,"[sc10x.Group@ident=='St']"))))
sc10x.Group <- SetIdent(object=sc10x.Group,cells.use=Epi.cell,ident.use=eval(parse(text=paste0("sc10x.Group@meta.data$Epi.res",opt.episubclust$r,"[sc10x.Group@ident=='Epi']"))))
sc10x.Group <- SetIdent(object=sc10x.Group,cells.use=St.cell,ident.use=eval(parse(text=paste0("sc10x.Group@meta.data$St.res",opt.stsubclust$r,"[sc10x.Group@ident=='St']"))))
sc10x.Group <- StashIdent(object=sc10x.Group,save.name=paste0("SubClust.res",opt$r))
postscript(paste0("./analysis/",opt$g,"/global",sub.folder,"/tSNE_Global.Merge.res",opt$r,".eps"))
postscript(paste0("./analysis/",opt$g,"/global",sub.folder,"/tSNE_Global.Merge.res.eps"))
plot <- TSNEPlot(object=sc10x.Group,pt.size=5,do.label=TRUE,label.size=10,do.return=TRUE)
plot <- plot+theme(axis.text.x=element_text(size=20),axis.text.y=element_text(size=20),axis.title.x=element_text(size=20),axis.title.y=element_text(size=20),legend.text=element_text(size=20))
plot <- plot+guides(colour=guide_legend(override.aes=list(size=10)))
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment