operator.substring(0, 3)); mnc = Integer.parseInt(operator.substring(3)); } StringBuffer cellinfo...=""; mytime = String.format("%d%02d%02d %02d:%02d:%02d",year,month,day,hour,minute,second); cellinfo.append...(mytime).append(","); //NetworkType int type = mTelephonyManager.getNetworkType(); cellinfo.append...(bid +","); }else{ sb.append("can not get the CDMA CellLocation"); cellinfo.append...; } String result = new String(cellinfo); return result; } 每一分钟采集一次,并将统计的信息按【采样时间,网络类型、移动国家码
ListCellInfo> allCellInfo = tm.getAllCellInfo(); //集合返回的第一个数据,allCellInfo.get(0)就是当前小区的数据 String...ss = allCellInfo.toString(); for(CellInfo cellInfo : allCellInfo){ if(cellInfo instanceof...CellInfoGsm) { CellInfoGsm infoGsm = (CellInfoGsm) cellInfo; CellIdentityGsm...instanceof CellInfoLte){ CellInfoLte cellInfoLte = (CellInfoLte) cellInfo;...instanceof CellInfoNr){ CellInfoNr cellInfoNr = (CellInfoNr) cellInfo;
scipy.stats as statsimport numpy as npcellinfo=all_data.obsgeneinfo=all_data.varmtx=all_data.X.Tcellinfo.to_csv...("cellinfo.csv")geneinfo.to_csv("geneinfo.csv")sio.mmwrite("sparse_matrix.mtx",mtx)!...pwd r中代码 cellinfo=read.csv("./cellinfo.csv",row.names = "X")head(cellinfo)geneinfo=read.csv("..../cellinfo.csv",# features = "./geneinfo.csv")counts=Matrix::readMM(file = "....)library(Seurat)kidney=CreateSeuratObject(counts = counts,project = "kidney",meta.data = cellinfo)dim
= cellInfo.tb, meta.cluster = cellInfo.tb$meta.cluster,...= data.table(cellInfo.tb) cellInfo.tb$meta.cluster = as.character(meta.cluster) if(is.factor(loc...)){ cellInfo.tb$loc = loc }else{cellInfo.tb$loc = as.factor(loc)} loc.avai.vec cellInfo.tb...[["loc"]]) count.dist cellInfo.tb[,table(meta.cluster,loc)])[,loc.avai.vec] freq.dist..., loc = cellInfo.tbloc, 为减少报错 建议修改我们输入矩阵的名字来适配函数 。
= cellInfo.tb, meta.cluster = cellInfo.tb$meta.cluster,...colname.patient = "patient", loc = cellInfo.tb$loc,...= data.table(cellInfo.tb) cellInfo.tb$meta.cluster = as.character(meta.cluster) if(is.factor(...loc)){ cellInfo.tb$loc = loc }else{cellInfo.tb$loc = as.factor(loc)} loc.avai.vec cellInfo.tb[["loc"]]) count.dist cellInfo.tb[,table(meta.cluster,loc)])[,loc.avai.vec]
的容器 * @author chroya */ public class WidgetLayout extends ViewGroup { //存放touch的坐标 private int[] cellInfo...(View child, int width, int height) { LayoutParams lp = new LayoutParams(width, height); lp.x = cellInfo...[0]; lp.y = cellInfo[1]; child.setOnLongClickListener(mLongClickListener); addView(child, lp);...MeasureSpec.EXACTLY, lp.height)); } } @Override public boolean dispatchTouchEvent(MotionEvent event) { cellInfo...[0] = (int)event.getX(); cellInfo[1] = (int)event.getY(); return super.dispatchTouchEvent(event);
/fibroblast.h5ad")cellinfo=all_data.obsgeneinfo=all_data.varmtx=all_data.X.Tcellinfo.to_csv("cellinfo.csv...pwd 第二步,在R中读取导出的数据,并创建seurat对象 cellinfo=read.csv("/home/data/t040413/heart_muscle/item1_NF_DCM_HCM/fibroblast.../cellinfo.csv",row.names = "X")head(cellinfo)geneinfo=read.csv("/home/data/t040413/heart_muscle/item1.../cellinfo.csv",# features = "....)library(Seurat)All.merge=CreateSeuratObject(counts = counts,project = "All.merge",meta.data = cellinfo
细胞信息/表型 # cellInfo$nGene 0) head(cellInfo) ?...cellInfo cellInfo) cellTypeColumn <- "Class" colnames(cellInfo)[which(colnames(cellInfo...# Modify if needed scenicOptions@inputDatasetInfo$cellInfo cellInfo.Rds" scenicOptions@inputDatasetInfo...cellInfo[which(rownames(cellInfo)%in% colnames(binaryRegulonActivity)),, drop=FALSE] regulonActivity_byCellType_Binarized...cellInfo_binarizedCells), cellInfo_binarizedCells$CellType),
, file="int/cellInfo.Rds") 可以看到前面的 nCores=4 参数,告诉我们的电脑,可以开启4个线程。...sce@assays$RNA@counts mat[1:4,1:4] exprMat =as.matrix(mat) dim(exprMat) exprMat[1:4,1:4] head(phe) cellInfo...<- phe[,c('seurat_clusters','nCount_RNA' ,'nFeature_RNA' )] colnames(cellInfo)=c('CellType', 'nGene...' ,'nUMI') head(cellInfo) table(cellInfo$CellType) ### Initialize settings library(SCENIC) db='cisTarget_databases..., file="int/cellInfo.Rds") ### Co-expression network genesKept <- geneFiltering(exprMat, scenicOptions
"sc.RData") # expr exprMat <- as.matrix(GetAssayData(Fibroblast, assay = "RNA", slot = "counts")) cellInfo...(org="hgnc", dbDir="SCENIC_libs", dbIndexCol = "motifs", nCores=10) scenicOptions@inputDatasetInfo$cellInfo...cellInfo.Rds" ### Build and score the GRN exprMat_log <- log2(exprMat+1) saveRDS(cellInfo,...file="int/cellInfo.Rds") # scenicOptions@settings$dbs <- scenicOptions@settings$dbs["10kb"] # Toy
<- get_cell_annotation(loom) close_loom(loom) dim(exprMat) exprMat[1:4,1:4] head(cellInfo) table(cellInfo...cellInfo.Rds" saveRDS(scenicOptions, file="int/scenicOptions.Rds") 需要注意的是,nCores=10 在部分电脑上面不适用哦...实战(以Seurat的pbmc3K数据集为例) 下面的代码复制粘贴即可运行,超级简单,如果是你自己的数据,你只需同样的模式做出来 exprMat 表达矩阵,和cellInfo的临床表型,就可以走这个SCENIC...<- pbmc3k@meta.data[,c(4,2,3)] colnames(cellInfo)=c('CellType', 'nGene' ,'nUMI') head(cellInfo) table...(cellInfo$CellType) ### Initialize settings library(SCENIC) # 保证cisTarget_databases 文件夹下面有下载好2个1G的文件
/GSE222427/GSM6923183_MC_scRNA.h5ad") all_data all_data.var.head() cellinfo = all_data.obs cellinfo...= all_data.obs geneinfo = all_data.var mtx=all_data.X # 保存 cellinfo.to_csv("cellinfo.csv") geneinfo.to_csv...library(qs) library(Matrix) mtx <- readMM( "sparse_matrix.mtx" ) mtx[1:4,1:4] dim(mtx) cl cellinfo.csv
<- data.frame(scRNA@meta.data) colnames(cellInfo)[which(colnames(cellInfo)=="orig.ident")] <- "sample..." colnames(cellInfo)[which(colnames(cellInfo)=="seurat_clusters")] <- "cluster" colnames(cellInfo)[which...(colnames(cellInfo)=="celltype_Monaco")] <- "celltype" cellInfo cellInfo[,c("sample","cluster","celltype...")] saveRDS(cellInfo, file="int/cellInfo.Rds") ##准备表达矩阵 #为了节省计算资源,随机抽取1000个细胞的数据子集 subcell <- sample(...用山脊图和小提琴图展示CEBPB调控网络的AUC值 pheatmap可视化SCENIC结果 library(pheatmap) cellInfo cellInfo.Rds
/fdff1375-aafc-48ef-b5b1-b1ff8466d92c.h5ad") cellinfo=all_data.obs geneinfo=all_data.var #mtx=all_data.X.T...raw_data = all_data.raw.X mtx = raw_data.T cellinfo.to_csv("cellinfo.csv") geneinfo.to_csv("geneinfo.csv...关于上面的代码得到的单细胞表达量矩阵,有一个问题: ls -lh inputs/ total 55G -rw-rw-r-- 1 t180559 t180559 537M 11月 9 23:44 cellinfo.csv
返回该页的总列数 for (int j = 0; j < sheet.getColumns(); j++) { String cellinfo...= sheet.getCell(j, i).getContents(); if(cellinfo.isEmpty()){...continue; } innerList.add(cellinfo);...System.out.print(cellinfo); } outerList.add(i, innerList);
为每个子集导出数据 def export_subset(subset, subset_name): # 导出细胞信息 subset.obs.to_csv(f"{subset_name}_cellinfo.csv...之前没有拆分的时候得到的单细胞表达量矩阵会肉眼看起来就很多: ls -lh inputs/ total 55G -rw-rw-r-- 1 t180559 t180559 537M 11月 9 23:44 cellinfo.csv...sparse_matrix.mtx 现在拆分成为了两个: $ ls -lh subset* -rw-rw-r-- 1 t180559 t180559 332M 11月 10 18:00 subset1_cellinfo.csv...34G 11月 10 18:30 subset1_sparse_matrix.mtx -rw-rw-r-- 1 t180559 t180559 205M 11月 10 18:31 subset2_cellinfo.csv
NetworkInfo.isAvailable.implementation = function(){ console.log("isAvailable") return true } var CellInfo...= Java.use("android.telephony.CellInfo") CellInfo.isRegistered.implementation = function(){
/integrated_lymphoid_organ_scrna.h5ad") cellinfo=all_data.obs geneinfo=all_data.var mtx=all_data.X.T...cellinfo.to_csv("cellinfo.csv") geneinfo.to_csv("geneinfo.csv") sio.mmwrite("sparse_matrix.mtx",mtx)...scRNA-seq/lessons/readMM_loadData.html # mtx=readMM( "inputs/sparse_matrix.mtx.gz" ) cl=fread( "inputs/cellinfo.csv.gz
android.telephony.CellIdentityLte; import android.telephony.CellIdentityWcdma; import android.telephony.CellInfo...@TargetApi(Build.VERSION_CODES.JELLY_BEAN_MR1) @Override public void onCellInfoChanged(ListCellInfo...@TargetApi(Build.VERSION_CODES.JELLY_BEAN_MR1) private void refreshStation(ListCellInfo> cellList)...false; mStation = ""; mCellType = Utils.TYPE_LTE; for (int i=0; i<cellList.size(); i++) { CellInfo...)); } @TargetApi(Build.VERSION_CODES.JELLY_BEAN_MR1) private void initHigherStation() { ListCellInfo
返回该页的总列数 for (int j = 0; j < sheet.getColumns(); j++) { String cellinfo...= sheet.getCell(j, i).getContents(); System.out.println(cellinfo);
领取专属 10元无门槛券
手把手带您无忧上云