Unfortunately, due to the complicated associations among cancer antigens and the possible induced T cell responses, currently, the practical strategy for identifying cancer-associated TCRs is the computational prediction based on TCR repertoire data. Several state-of-the-art methods were proposed in recent year or two; however, the prediction algorithms were still weakened by two major issues. To facilitate the computational processes, the algorithms prefer to decompose the original TCR sequences into length-fixed amino acid fragments, while the first dilemma comes as the lengths of cancer-associated motifs are suggested to be various. Moreover, the correlations among TCRs in the same repertoire should be further considered, which are often ignored by the existing methods. We here developed a deep multi-instance learning method, named DeepLION, to improve the prediction of cancer-associated TCRs by considering these issues. First, DeepLION introduced a deep learning framework with alternative convolution filters and 1-max pooling operations to handle the amino acid fragments with different lengths. Then, the multi-instance learning framework modeled the TCR correlations and assigned adjusted weights for each TCR sequence during the predicting process. To validate the performance of DeepLION, we conducted a series of experiments on several cohorts of patients from nine cancer types. Compared to the existing methods, DeepLION achieved, on most of the cohorts, higher prediction accuracies, sensitivities, specificities, and areas under the curve (AUCs), where the AUC reached notably 0.97 and 0.90 for thyroid and lung cancer cohorts, respectively. Thus, DeepLION may further support the detection of cancers from TCR repertoire data. DeepLION is publicly available on GitHub, at https://github.com/Bioinformatics7181/DeepLION, for academic usage only.Recent studies highlight the potential of T cell receptor (TCR) repertoires in accurately detecting cancers  T cells that respond to tumor antigens are the central mediators of cancer immunity . For a cz-mers, which limits these approaches to identifying length-fixed key motifs, is considered to lead to information loss and may harm subsequent model classification.However, accurately predicting the caTCRs is quite challenging work, mainly due to the tremendous heterogeneity on personal antigen landscapes, while the lack of knowledge about the cancer antigens inducing spontaneous T cell responses brings additional difficulty . To compde novo prediction of caTCRs  status from the resulting catalog of CDR3 sequences . Yokota’f caTCRs . Antigenf caTCRs . The canf caTCRs  attemptef caTCRs , predictIn summary, there is a dearth of caTCR prediction approaches that take into account the cancer-associated biochemical motifs with various lengths and correctly model the correlations among TCRs in the same repertoire. To bridge this gap, we developed a deep MIL method called DeepLION in this study to improve the prediction of caTCRs using TCR-seq data . On one k TCRβ CDR3 sequences with the highest abundance in the repertoire were selected and encoded into the matrixes using AA biochemical features. After data preprocessing, the TCR matrixes with different sizes were fed into a deep CNN model, where the biochemical features of key motifs with various lengths were extracted by alternative convolution filters and 1-max pooling operations, and then the scores of TCRs, the probabilities that they were caTCRs, were calculated. Finally, a one-layer linear classifier L′ was employed to aggregate k TCR scores as the cancer score of the repertoire, which is used to predict whether it is cancerous.DeepLION is a deep MIL method based on TCR-seq data for caTCR prediction. The workflow of DeepLION consisted of three parts: data preprocessing, the CNN for TCRs, and MIL . First, 1) too short (<10) or too long (>24) sequences; 2) sequences containing special characters ; 3) incomplete sequences, according to the ImMunoGeneTics (IMGT) nomenclature (4) sequences where variable gene locus was not solved. There were some overlapping TCR sequences between healthy individuals and cancer patients, which were considered irrelevant to cancer and therefore also needed to be excluded. We used known training data to generate a reference dataset (denoted as DR) containing sequences that appeared at a high frequency in both healthy individuals and cancer patients . Any sequences in each sample appearing in the DR were removed. After the above sequences were removed, the remaining TCR sequences were sorted in descending order of cloning frequency and the top k sequences were extracted for downstream analysis.We collected the CDR3 of TCRβ from TCR-seq data to study. Considering that low-quality CDR3 sequences will affect the downstream analysis, the following types of sequences were removed as described in the previous study : 1) too nclature , not stal is able to be encoded by a 20 × d feature matrix for 20 AAs into an l × d TCR matrix. The AA index database (d = 15) to encode the TCR sequences into matrixes.The raw TCR sequences were not directly input to the CNN because their antigen-binding ability was not well represented. AAs in TCR sequences can be represented by biochemical features, and a TCR sequence with length database  documentdatabase , and Atcdatabase . Beshnovdatabase . Considel × d, the model extracted its features by a set of convolution filters with various sizes respectively, performed 1-max pooling operations for the low-dimensional feature maps obtained by each convolution filter, and concatenated the pooled results to generate a TCR feature vector. The TCR score, the probability of being a caTCR, was obtained by a one-layer linear classifier finally.The CNN is able to predict whether a TCR sequence is associated with cancer. TextCNN in natural language processing (NLP) firstly applied the CNN model to sequence analysis . Referrijth convolution filter ith TCR matrix, a to row b in d TCR matrix shown in d performed a complete convolution operation on the matrix from top to bottom, it could be regarded as extracting the biochemical features of the 2-mers in TCRs such as "CA", "AS", etc., and finally obtaining the 10 × 1 feature map, the feature set of all 2-mers, which probably included cancer-specific motifs. The filters with other sizes performed similar convolution operations. Because the frequencies of key motifs with different lengths varied, the numbers of convolution filters with various sizes were adjusted to give them appropriate weights in the model. ReLU was chosen as the activation function following the convolution operations due to its low computational complexity. Additionally, it can avoid the vanishing gradient or exploding gradient problems that Sigmoid and Tanh can cause. And the disadvantage of ReLU, the dead ReLU problem, was mitigated by using the Xavier initialization  the element-wise maximum function (2) the element-wise average function (3) the log-sum-exp (LSE) function  . These aUltimately, a one-layer linear classifier L was applied to aggregate the features extracted from each convolution kernel and predict the score for that TCR sequence. L that assigned scores to the TCRs is given by:The CNN model jointly learns the various convolution filters and L so that it is end-to-end trainable and the preprocessed TCRs and the corresponding labels are needed for model training. Because the probability that a TCR is a caTCR obeys a Bernoulli distribution, the log-likelihood function  was used as the loss function to train the model, which is defined as:During the training process, random dropouts at a rate of 40% were applied to L to mitigate overfitting.l = 24) to ensure the consistency of the dimensionality of the input TCR matrixes. Because the features of all motifs containing zero viewed as non-key motifs were discarded after the 1-max pooling operations in the model, the classification ability of the model did not deteriorate.Because zero-padding will alter the distribution of input data, DeepCAT  built fik TCRs collected from repertoires to predict the repertoire. Predicting whether a repertoire is cancer-associated from the TCRs in every repertoire can be described as MIL, where the TCRs are instances and the repertoires are bags. The standard MIL assumption assumes that each instance in a bag can be classified as either positive (1) or negative (0), and the label of a bag is 1 when including one or more positive instances . OstmeyeInstead of simply taking the max value  or the aWe conducted a series of experiments on several cohorts of patients covering multiple cancers and healthy donors to validate the performance of DeepLION. In We used the publicly available TCR-seq data from Adaptive Biotechnologies immuneACCESS online database (IA), which contains eight groups of peripheral blood mononuclear cell (PBMC) samples with diverse cancer types and one group of non-cancer PBMC samples. To validate the performance of the models on Asian patients, the TCR-seq data from the clinical database of Geneplus Technology Ltd. in Shenzhen (Geneplus) were also used , which in = 30,000) and non-cancer  TCR CDR3 sequences. The cancer sequences were derived from The Cancer Genome Atlas (TCGA) (2 (n = 120) (1 (n = 666). The test data consisted of two datasets (T1 and T2). T1 consisted of eight groups of samples, each of which contained cancer and H1 PBMC samples from IA. All TCR-seq data in T2 were obtained from Geneplus, which were collected from Asian populations. T2 was composed of two groups of samples: the first group contained THCA PBMC & TIL samples (n = 170) and the PBMC samples from the healthy individuals H3 (n = 260), and the second group contained lung cancer PBMC and TIL samples (n = 184) and H3 PBMC samples. In s (TCGA)  tumor RNs (TCGA) , whereasn = 120) , which a2 to train and test the entire DeepLION due to the larger sizes of cancer samples in T2 (In es in T2 . The samCAT)  when predicting the caTCRs, we conducted experiments to compare MCNN with MCAT. MCAT and MCNN shared the same training data (CAT.DeepCAT (MCAT)  is curreing data , and we l × 15 TCR matrixes (d = 15) by the Beshnova matrix  as the training set and used them to train the model for 1,000 epochs at a learning rate of 0.001 with the assurance that the model reached convergence. The remaining training data were used as the validation set and AUCs were estimated to evaluate the trained models. Ultimately, the five trained models had similar AUCs, and the model with the highest AUC (0.85) was selected as the final model. The trained MCAT was obtained from Github.Before the training process, all the training sequences were encoded into a matrix . To gaink = 10,000) of each sample were extracted after low-quality sequences were removed. Second, we used iSMART  and AUCs of both models were estimated for evaluating the models , indicating that it had the better feature extraction and prediction ability for TCRs.To further compare the performance of these two models, M results . As showCAT and MCNN, we expected that the entire DeepLION (MLION) as a MIL method was capable of achieving more accurate caTCR prediction after correctly modeling the correlations among TCRs. Because the logistic regression model combined with MIL (denoted as MLOG) (LION with it.In comparison with Mas MLOG)  is a clak = 100) from each sample and encoded them into l × 15 TCR matrixes (d = 15) by the Beshnova matrix  were determined by the Youden index . The ROC curves were generated based on the predicted probabilities of all models on the two samples  and extract the features of motifs of various lengths from TCRs to make more accurate TCR prediction, which resulted in the better performance on the test data   (2 could be explained by possible differences in TCR repertoires between patients of different races.In est data . Howevernd AUCs) . This co for T2) , indicatLOG performed the worst performance on the samples (CAT and MCNN, their accuracies and sensitivities on two samples were significantly lower than those of MLION due to the incorrect definition of the repertoire cancer score and the possible differences in the repertoires of patients from different races (LION used MIL to learn the correlations among TCRs in the repertoire of the patients with the same cancer type, and assign the adjusted weights to each TCR when calculating the cancer scores of the repertoire. Therefore, MLION was capable of predicting the caTCRs and classifying the samples more accurately than existing methods.In  samples , because samples  to chara samples , and it nt races . DiffereWhen the amounts of training data are small, overfitting is a concern with deep learning models. To reduce overfitting, we simplified the model by using one-layer linear classifiers instead of multi-layer linear classifiers. During the training process, we applied random dropouts at a rate of 40% to each linear classifier and employed early stopping  to the mThe results of two cross-validations indicated that our model had higher specificities than sensitivities on both THCA and lung cancer . We reask and the learning rate, which is easily applied. The computational complexity of the model is lower when k is smaller, but the information of TCRs used by the model is less, which could reduce the model performance. Thus, k should be as small as possible while ensuring satisfactory model performance. Because we observed that the model performance was unsatisfactory when k < 100 through experiments, we finally set k to 100 in our experiments. In addition, the abundance of TCRs affects the predictions of the model. We discovered that the model performance deteriorated if we randomly extracted the 100 TCRs instead of the top 100 TCRs. Because the learning rate is usually set to 0.001, we used this value as well.DeepLION has few adjustable hyperparameters except for the number of TCRs extracted from one repertoire In future work, we will apply DeepLION to other cancer types. And we plan to improve our method to make it able to extract the shared correlations among TCRs of patients with various cancers so that the trained model can be applied to detect various cancers accurately. In this method, we will utilize TCRα sequences as well as TCRβ sequences for analysis and explore a better encoding operation to characterize TCRs.DeepLION introduces a deep MIL framework to consider the various length of the cancer-associated motifs and the correlations among TCRs, achieving a higher prediction accuracy in cancer detection from TCR repertoire data than the current state-of-the-art methods. Thus, DeepLION has the potential to support cancer detection from TCR repertoire data.


In studies of cellular function in cancer, researchers are increasingly able to choose from many -omics assays as functional readouts. Choosing the correct readout for a given study can be difficult, and which layer of cellular function is most suitable to capture the relevant signal remains unclear.We consider prediction of cancer mutation status (presence or absence) from functional -omics data as a representative problem that presents an opportunity to quantify and compare the ability of different -omics readouts to capture signals of dysregulation in cancer. From the TCGA Pan-Cancer Atlas that contains genetic alteration data, we focus on RNA sequencing, DNA methylation arrays, reverse phase protein arrays (RPPA), microRNA, and somatic mutational signatures as -omics readouts. Across a collection of genes recurrently mutated in cancer, RNA sequencing tends to be the most effective predictor of mutation state. We find that one or more other data types for many of the genes are approximately equally effective predictors. Performance is more variable between mutations than that between data types for the same mutation, and there is little difference between the top data types. We also find that combining data types into a single multi-omics model provides little or no improvement in predictive ability over the best individual data type.Based on our results, for the design of studies focused on the functional outcomes of cancer mutations, there are often multiple -omics types that can serve as effective readouts, although gene expression seems to be a reasonable default option.The online version contains supplementary material available at 10.1186/s13059-022-02705-y. Although cancer can be initiated and driven by many different genetic alterations, these tend to converge on a limited number of pathways or signaling processes . As drivTP53  and α = . Using the grid search results, for each evaluation fold, we selected the set of hyperparameters with the optimal area under the precision-recall curve (AUPR), averaged over the three inner folds.For each target gene, we evaluated model performance using two replicates of 4-fold cross-validation, where train and test splits were stratified by cancer type and sample type. That is, each training set/test set combination had equal proportions of each cancer type  and each sample type . To choose the elastic net hyperparameters, we used 3-fold nested cross-validation, with a grid search over the following hyperparameter ranges: Area under the receiver-operator curve (AUROC)  and areat-tests, where performance measurements derived from the same cross-validation fold are considered paired measurements. We used this approach to compare a model trained on true labels with a model trained on permuted labels , and to compare a model trained on data type A with a model trained on data type B .Recall that for each target gene and each -omics dataset, we ran two replicates of 4-fold cross-validation, for a total of eight performance results. To make a statistical comparison between two models using these performance distributions, we used paired-sample H0, we set a conservative corrected threshold of p = 0.001; we were able to estimate the number of false positives by examining genes with better performance for permuted mutation labels than true labels. We chose this threshold to ensure that none of the observed false positive genes were considered significant, since we would never expect permuting labels to improve performance. However, our results were not sensitive to the choice of this threshold, and we display cutoffs of p = 0.05 and p = 0.01 in many of our plots as well.We corrected for multiple tests using a Benjamini-Hochberg false discovery rate correction. For experiments where we chose a binary threshold for accepting/rejecting 10(sample mutation count) included as covariates, as well as a one-hot encoded variable for cancer type. To ensure that the per-feature information content was comparable between -omics data types, we preprocessed the -omics datasets using PCA and extracted the top k principal components; in the case where the number of features in the original dataset was less than k, we used all available PCs  where p is the number of features in the unprocessed dataset). We plot results over multiple values of k: k ∈ {10, 100, 500, 1000, 5000}. As a complementary comparison to mutation prediction, we constructed predictors of patient survival using the clinical data available from the GDC, in the TCGA-CDR-SupplementalTableS1.xlsx file. Following the methods described in , as the λ =  and α = .To model pan-cancer survival (results shown in main paper), we used the elastic net Cox regression implementation in scikit-survival . To select hyperparameters for the elastic net Cox regression model, we performed a grid search over 10(sample mutation count), and a one-hot encoded variable for sample cancer type.We measured survival prediction performance using the censored concordance index (c-index) , which qTo predict mutation presence or absence in cancer genes using multiple data types simultaneously, we concatenated individual datasets into a large feature matrix, then used the same elastic net logistic regression method described previously. For this task, we considered only the gene expression, 27K methylation, and 450K methylation datasets. We used only these data types to limit the number of multi-omics combinations; the expression and methylation datasets resulted in the best overall performance across the single-omics experiments, so we limited combinations to those datasets. In the main text, we report results using the top 5000 principal components for each dataset, which ensures that most variance is captured (approximately 95–98% of variance for each data type). In Additional file EGFR, IDH1, KRAS, PIK3CA, SETD2, and TP53. We selected these genes because we had previously observed that they have good predictive performance and because they represent a combination of alterations that have strong gene expression signatures  and strong DNA methylation signatures .To construct the multi-omics models, we considered each of the pairwise combinations of the datasets listed above, as well as a combination of all 3 datasets. When combining multiple datasets, we concatenated along the column axis and included covariates for cancer type and sample mutation burden as before. For all multi-omics experiments, we used only the samples from TCGA with data for all three data types . We considered a limited subset of well-performing genes from the merged cancer gene set as target genes, including For the experiments predicting mutation status using a 3-layer fully connected neural network, described in the “Additional file 1. All supplementary figures and supplementary information.Additional file 2. Number of samples from each TCGA cancer type that are “dropped” as more data types are added to the analysis. The “base” column indicates the number of samples that are present per cancer type in the final intersection of all data types  and somatic mutations).Additional file 3. Review history.


The use of bulk transcriptomics to validate Bulk2Space unveils, in particular, the spatial variance of immune cells in different tumor regions, the molecular and spatial heterogeneity of tissues during inflammation-induced tumorigenesis, and spatial patterns of novel genes in different cell types. Moreover, Bulk2Space is utilized to perform spatial deconvolution analysis on bulk transcriptome data from two different mouse brain regions derived from our in-house developed sequencing approach termed Spatial-seq. We have not only reconstructed the hierarchical structure of the mouse isocortex but also further annotated cell types that were not identified by original methods in the mouse hypothalamus.Uncovering the tissue molecular architecture at single-cell resolution could help better understand organisms’ biological and pathological processes. However, bulk RNA-seq can only measure gene expression in cell mixtures, without revealing the transcriptional heterogeneity and spatial patterns of single cells. Herein, we introduce Bulk2Space ( Current methods to reanalyze bulk RNA-seq at spatially resolved single-cell resolution have limitations. Here, the authors develop Bulk2Space, a spatial deconvolution algorithm using single-cell and spatial transcriptomics as references, providing new insights into spatial heterogeneity within bulk tissue. Advances in spatially resolved transcriptomics4 have made it possible to understand the cell composition, molecular architecture, and functional details of tissues at unanticipated spatial levels6. State-of-the-art experimental technologies, including image-based methods10, spatial barcoding RNA-seq methods14, and laser capture microdissection-based methods16, have been developed to address either high throughput measuring of cells, unbiased detection of mRNA species, or single-cell resolution. To investigate the molecular variation during biological and pathological processes at a higher resolution, each sample is encouraged to be analyzed by spatially resolved single-cell transcriptomics, which is not yet fully achieved and is time-consuming, costly, and difficult to scale up17. Meanwhile, with investment for almost two decades, RNA-seq has been extensively applied in transcriptome analysis18, with many large projects having been carried out, such as the Encyclopedia of DNA Elements (ENCODE)19, The Cancer Genome Atlas (TCGA)20, and projects of the International Cancer Genome Consortium (ICGC)21. A wealth of bulk RNA-seq data has become a legacy for biological and clinical research22. Thus, reanalysis of the enormous amount of bulk data to explain both cellular diversity and spatial expression patterns is a challenging but consequential task.Tissue complexity is portrayed by the spatial diversity and heterogeneity of cells23, CIBERSORT24, and MuSiC25 can only extrapolate proportions of cell types from bulk RNA-seq data and have failed to further generate single-cell data, let alone map them to tissue coordinates. The emergence of an approach that can efficiently decompose bulk RNA-seq data into spatially resolved single-cell expression profiles is expected to reveal the cell diversity of complex tissue and the spatial expression variation simultaneously.In silico methods have great potential to predict spatial heterogeneity from bulk RNA-seq data at single-cell resolution by integrating cutting-edge technologies. Several approaches such as CPM9, and the other is a spatial barcoding method without single-cell resolution14. Taken all, Bulk2Space showed a robust performance across multiple datasets and conditions and is an open-access algorithm on GitHub (https://github.com/ZJUFanLab/bulk2space).Herein, we introduce Bulk2Space, a spatial deconvolution algorithm based on deep learning frameworks, which generates spatially resolved single-cell expression profiles from bulk transcriptomes using existing high-quality scRNA-seq data and spatial transcriptomics as references. We hypothesize that the process of scRNA-seq is similar to sampling cells from bulk tissue, and each selected cell is labeled with a unique barcode. Consequently, bulk transcriptome data can be used as a weighted collection of single-cell expression data in a defined clustering space of cells. Bulk2Space first generates single-cell transcriptomic data within the clustering space to find a set of cells whose aggregated data is proximate to the bulk data. Next, the generated single cells were allocated to optimal spatial locations using a spatial transcriptome reference. For this step, we chose as a spatial reference one of the two most commonly used spatially resolved transcriptomics technologies. One is an image-based method with limited target genes26. Thus, we assume that bulk transcriptomics data can be decomposed into single-cell transcriptomics data by a well-designed deconvolution algorithm (Step 1). Subsequently, in the second step, the above-mentioned two prevailing spatially resolved transcriptomics methods, though, failed in either achieving single-cell resolution or delineating the whole transcriptome, can provide reference locations for single cells generated in the first step of Bulk2Space based on the similarity of their expression profiles (Step 2)28. As a consequence, it could be rationally conceived that the combination of single-cell profiles and spatial transcriptomics is expected to overcome technical bottlenecks and accomplish the spatially resolved single-cell deconvolution of bulk transcriptomes 33, is employed to simulate a given number of single cells within the characterized clustering space of each cell type. The simulation stops when the training loss no longer reduces, thus deconvolves the heterogeneous bulk transcriptome into single-cell transcriptome data. Instead of only calculating the abundance values of cell types, as performed by other methods, such as Cell Population Mapping (CPM)23, CIBERSORT24, and ImmuCC26, Bulk2Space can generate biologically feasible single-cell expression profiles.For the deconvolution of bulk transcriptomics data, we hypothesize that the process of single-cell sequencing identifies with the process of sampling from the tissue, while the ratio between different cell types is related to the zone of the tissue, the ways of single-cell capturing, and the size of the cell itself. However, even if the ratio between cell types changes, the state of each cell type still fluctuates within a relatively stable high-dimensional space, which is namely the clustering space of cell types. This hypothesis has been supported by several studiesFor spatial mapping, the single-cell profiles generated in the first step are assigned to the reference tissue section based on an optimization strategy. In the second step, we consider two of the most commonly used spatially resolved transcriptomics approaches as the spatial reference, namely, spatial barcoding-based RNA-seq methods and image-based targeted methods.14 (100 μm in diameter), Visium (55 μm in diameter), Slide-seq13 (10 μm in diameter), etc. As shown in Fig. 34, SpatialDWLS35, stereoscope36, and SPOTlight37, we first calculate the cell-type composition of each spot. The difference is that we then map the generated single cells into the recommended spots based on the similarity of their cell expression profiles and ensure that the proportions of cell types in each spot are consistent with the calculated results. Since Bulk2Space generates spatially resolved single-cell transcriptomics data from bulk RNA-seq, the spatial heterogeneity of individual cells can be analyzed, which cannot be realized by RCTD, SpatialDWLS, stereoscope, and SPOTlight.Spatial barcoding-based methods employ arrayed reverse transcription primers with unique positional barcodes to preserve the spatial information of mRNA via in situ complementary DNA (cDNA) synthesis. Such methods could provide the whole transcriptome as well as the location of each sequenced spot after decoding the spatial barcodes. However, these methods are unable to achieve single-cell resolution, because the spots are customized in shape and size, such as ST38, such as MERFISH7, STARmap9, seqFISH10, etc. The pairwise similarity between cells is calculated based on genes shared by both datasets, and eventually, each generated single cell is robustly mapped to an optimized coordinate of the target cell in the spatial reference. The resulting spatially resolved single-cell RNA-seq data can provide unbiased transcriptomes of individual cells and improve the gene coverage.As illustrated in Fig. Taken all, unlike other computational methods that focus only on either of the two spatially resolved transcriptomics approaches, Bulk2Space takes into account both techniques to greatly increase the scalability, applicability, and reference data of the algorithm.To demonstrate the robustness of the deconvolution step of Bulk2Space, a benchmark test was performed using 30 paired simulations (both bulk and single-cell data were generated from the same datasets) from 10 different high-quality single-cell datasets across human blood, brain, kidney, liver, and lung, and mice brain, kidney, lung, pancreas, and testis Fig. , and 12 33, generative adversarial networks (GAN)39, and conditional GAN (CGAN)40, were introduced here for the benchmarking of different methods using 30 paired single-cell datasets. The gene expression correlation between the generated single-cell data and input bulk data was calculated to evaluate and compare the three candidate algorithms. As illustrated in Fig. First, for 30 paired simulations, each single-cell transcriptome dataset was divided into two parts, one for reference and the other for the synthesis of bulk data. The procedure for bulk data synthesis is shown in Fig. 23, CIBERSORT24, and ImmuCC26, can only predict cell-type proportions instead of gene expression of generated data, we compared Bulk2Space with GAN, CGAN, and a Bayesian deconvolution method termed bMIND41. As illustrated in Fig. We then benchmarked the deconvolution step of Bulk2Space using 12 unpaired simulation data of mice pancreas. Because other deconvolution methods, such as CPM42. As shown in Fig. To further investigate the robustness of the single-cell generation of Bulk2Space, we introduced two noise mechanisms to test the performance of the algorithm Fig. . One mec14, high-definition spatial transcriptomics (HDST)11, and Slide-seq13, 10 Visium, etc. These methods are based on tissue microregions with certain regular shapes (spots), and cannot achieve single-cell resolution. The other is image-based in situ transcriptomics, including MERFISH7, seqFISH10, and STARmap9. These methods can only measure the expression of target genes but cannot cover the whole transcriptome. To overcome the bottlenecks of the two approaches, we designed corresponding spatial assignment strategies.In the second step, Bulk2Space assigns the generated single cells to spatial coordinates based on a spatially resolved transcriptome reference Fig. , d. Ther34, SpatialDWLS35, stereoscope36, and SPOTlight37 was then conducted using 50 paired simulation datasets. These methods were benchmarked for the optimization of cell-type composition and spatial gene expression patterns. As shown in Fig. The first strategy was designed to map single cells to spots in spatially resolved transcriptomics based on spatial barcoding. In this step, we first used paired synthetic data to test the performance of Bulk2Space. The data synthesis procedure is illustrated in Fig. GSE113576”) and MERFISH data (image-based reference) of the mouse hypothalamus tissue from the same experiment43 were used as paired datasets to test the performance of the Bulk2Space algorithm. Another scRNA-seq data44 derived from a separated experiment was used as unpaired single-cell data. We wanted to find the shortest path that could shift single cells to optimal locations. First, a nonparametric empirical Bayes network was used to eliminate the expression differences between the single-cell data and spatially resolved transcriptome data. As illustrated in Fig. The second spatial mapping strategy uses image-based targeted methods. A scRNA-seq data  and the PDAC tissues, one scRNA-seq data47, and one spatial transcriptomics data47 were derived from two individual experiments and three different technologies. The scRNA-seq data sequenced by inDrop-seq51 were used as the single-cell reference for the deconvolution of PA tissue and PDAC bulk data, and the spatial barcoding-based ST data were used as the spatial reference.Based on the success in the spatial deconvolution of PDAC using simulated data and discrete slices, we further verified the performance of the Bulk2Space algorithm using biological bulk RNA-seq data. As shown in Fig. The PA and PDAC bulk data were deconvolved into single-cell data with different cell-type proportions by Bulk2Space. We compared the cell-type proportions of single cells generated from PA and PDAC bulk data with Bulk2Space. As shown in Fig. Here, we focused on the PDAC bulk data. The expression of cell-type-specific marker genes between generated single-cell profiles by Bulk2Sapce and the reference data was highly correlated Fig. . Then, eIn addition to linking the histomorphology and transcriptomics in pathological tissues, another application scenario of Bulk2Space is to reconstruct the structure of tissues with spatial patterns. For instance, the spatial organization of the isocortex region of the mouse brain exhibits a layered pattern. Therefore, Bulk2Space was applied to reconstruct the hierarchical structure of the mouse isocortex region through spatial deconvolution of the bulk transcriptomics data. The bulk transcriptomics data of mouse isocortex were sequenced by our in-house developed multiplexed RNA-seq approach, termed Spatial-seq. The detailed information for Spatial-seq was described in the ‘Methods’ section and illustrated in Fig. 52. The result scRNA-seq data were used as the single-cell reference. A sagittal section of the mouse brain was divided into two parts and sequenced using 10X Visium to obtain spatial transcriptomics data of the isocortex region. The spatial reference data were downloaded from 10X datasets. The detailed information of datasets used in this study was summarized in Supplementary Data As shown in Fig. The bulk data were first deconvolved into single-cell RNA-seq data Fig. . Subsequ34, SpatialDWLS35, stereoscope36, and SPOTlight37, Bulk2Space can generate spatially resolved single-cell transcriptomics data from bulk RNA-seq. Besides, Bulk2Space allowed us to analyze the spatial heterogeneity of individual cells from the spatially resolved transcriptomics data without single-cell resolution.Different from traditional spatial deconvolution algorithms such as RCTDThe Bulk2Space algorithm was also used to spatially deconvolve bulk transcriptome data derived from the hypothalamus region of the mouse brain using Spatial-seq, to explain the spatial distribution of single cells and gene expression. The resources of the bulk, single-cell, and spatial data was illustrated in Fig. After deconvolution of the bulk RNA-seq data of the mouse hypothalamus by Bulk2Space, the clustering space of the generated single cells was close to that of the MERFISH data Fig. . The genMeanwhile, owing to the limited number of measured target genes, some ambiguous cells in MERFISH data could not be further identified according to their expression profiles. However, using Bulk2Space, the generated single cells with unbiased gene expression were assigned to the spatial context, thus further clustering these ambiguous cells using novel genes that were absent in MERFISH data Fig. . Meanwhi53. To explore whether Bulk2Space could identify the cellular and molecular pathways that coordinate the tumor-promoting effects in inflammation-induced cancer, we deconvolved the bulk transcriptome data of prostate cancer and mapped single cells generated by Bulk2Space to the corresponding spatial references, including normal glands, inflammatory tissue, and tumor sites. The resources of the bulk (from TCGA), single-cell54, and spatial data55 were listed in Supplementary Data Tumor development is linked to chronic infection, dietary factors, obesity, inhaled pollutants, tobacco use, and autoimmunity. The unifying principle underlying these processes is inflammation, which is an aberrantly prolonged form of a protective response to a loss of tissue homeostasisThese tissue regions were isolated from the prostate, and three of the sections were subjected to RNA-seq based on spatial barcoding Fig. . Next, B53. Bulk2Space results were consistent with this phenomenon.During the progress of inflammation-induced prostate cancer, CAFs accumulated in normal glands at the early stage, resulting in high expression of inflammatory factors and promoting the occurrence of local inflammation, a fundamental innate immune response to perturbed tissue homeostasis, thus leading to tissue cancerization56. The spatial locations of cells may determine their identity and how they interplay with each other in the microenvironment58. However, there are many technical challenges, and thus, such a technology has not been fully realized yet. Traditional bulk transcriptome data can provide gene expression patterns and reflect the overall status of tissue, which is widely used in studies on the occurrence and development of diseases. Nevertheless, disease-inherent cell composition and spatial distribution are difficult to analyze. Although several attempts can infer the cell-type proportions from traditional RNA-seq data, understanding bulk tissue at single-cell spatial resolution remains a pressing need in the field. Cell identity can be characterized by the clustering space of single-cell gene expression profiles59, and expression features can be stably retained across different conditions, technologies, and species29. Based on this, we used a deep learning model, termed β-VAE, to generate single-cell profiles with biological significance within the clustering space of each cell type and map them accurately to tissue coordinates, thus deconvolving the bulk transcriptomics into spatially resolved single-cell transcriptomics data.Understanding the transcriptional heterogeneity within the tissue from the perspective of single-cell spatial resolution and full gene coverage is an essential direction for the development in the field of biological sciencesAs thoroughly considered the merits and demerits of the widespread use of two spatially resolved transcriptomics technologies, we employed different spatial mapping strategies for each method. For image-based in situ hybridization, Bulk2Space could predict the spatial expression of mRNA species apart from the target genes. Moreover, Bulk2Space can help annotate cells whose types are difficult to further distinguish by targeted methods. For spatial barcoding-based RNA-seq, each sequenced tissue region contains transcripts from different cells and can thus be regarded as a mixture of cells, not allowing single-cell resolution. Bulk2Space can assign single cells to optimal spots, and these mixtures are split into collections of individual cells, thus providing a spatially resolved single-cell deconvolution strategy for these spatial data. Our results showed that Bulk2Space had great biological and clinical application prospects, including linking tissue molecular characteristics with histological phenotypes, revealing the spatial specific variation of cells, discovering the spatial expression pattern of novel genes, achieving more refined cell clustering, and predicting the molecular mechanism underlying the progression of the disease.All scRNA-seq, spatially resolved transcriptomics, and bulk RNA-seq datasets used in this study were collected from high-quality publications, Gene Expression Omnibus (GEO), and The Cancer Genome Atlas (TCGA), wherein unannotated, ambiguous, or low quality-cells were excluded. The detailed description of each dataset was summarized in Supplementary Data The Bulk2Space was developed on two workstations, as listed below.Dell Precision Tower 7820 Workstation, CPU , RAM , Hard Drive , Graphics Card , Operating System (Ubuntu 16.04), Running Environment .Dell Precision Tower 7920 Workstation, CPU , RAM , Hard Drive , Graphics Card , Operating System (Ubuntu 18.04), Running Environment .43 et al., we filtered 841 ambiguous cells and 88 unstable cells. For human prostate cancer scRNA-seq data by Wu54 et al., we filtered 183 unassigned cells. All cells of other scRNA-seq as well as spatially resolved transcriptomics datasets were retained. For mouse hypothalamus MERFISH data, we filtered 5 “blank” barcodes as well as the Fos gene, whose expression value in all cells was ‘NA’. For human prostate cancer RNA-seq data, we used biomaRt (version 2.48.3) to transform ensemble id to gene name. For all scRNA-seq and spatially resolved transcriptomics datasets, the raw counts were normalized using the global-scaling normalization method “LogNormalize” by Seurat (version 4.0.4)60. For the MERFISH dataset, the normalized data was determined as the raw count per cell divided by the cell volume and scaled by 1000.All data were preprocessed using R (version 4.1.1). For mouse brain scRNA-seq data by Moffitti . Given the gene expression vector For a given bulk RNA-seq dataset, we aimed to calculate its cell-type proportions firstly, and then generate single-cell gene expression profiles based on the calculated proportions. Since cell type and gene expression of all single cells can be accessed from the scRNA-seq data reference, we collected cells with the same cell type and then average their gene expression. This average vector pi is the proportion of cell type i.Here, pi by minimizing the squared discrepancies between observed data.p = T is the proportion vector to be estimated.We applied least square estimation (LSE) to estimate p(v|x) = ∑klog p(vk|x); and conditionally dependent factors x are generated by a true world simulator S using the corresponding ground truth data generative factors: pθ = S, where θ is the generative model parameter.Let X only, can learn the joint distribution of the data x and a set of generative latent factors z (M ≥ K) that can be used to generate the observed data x; i.e., pθ (x|z) ≈p = S. However, since the integral of the marginal likelihood pθ(x) = ∫pθ(z)pθ(x|z) dz is intractable , the true posterior density pθ (z|x) = pθ(x|z)pθ(z)/pθ(x) is intractable.We wanted to develop an unsupervised deep generative model that, using samples from x, we described the inferred posterior configurations of the latent factors z through a probability distribution qϕ(z|x): an approximation to the intractable true posterior pθ(x|z). We aimed to ensure that the inferred latent factors qϕ(z|x) capture the generative factors v in a disentangled manner. A disentangled representation can be defined as one where single latent units are sensitive to changes in single generative factors, while being relatively invariant to changes in other factors. In a disentangled representation, knowledge about one factor can generalize to novel configurations of other factors. The conditionally dependent data generative factors w can remain entangled in a separate subset of z that is not used for representing v.To solve this problem, for a given observation An intuitive approach was to minimize the KL divergence between the approximate and the true posterior:Here, qϕ (z|x), we introduced a constraint over it by trying to match it to a prior p(z) that can both control the capacity of the latent information bottleneck, and embodies the desiderata of statistical independence mentioned above. We set the prior to be an isotropic unit Gaussian ϵ specifies the strength of the applied constraint. Re-writing the above equation as a Lagrangian under the KKT conditions, we obtain:β is the regularization coefficient that constrains the capacity of the latent information channel z and puts implicit independence pressure on the learnt posterior due to the isotropic nature of the Gaussian prior pθ(z). Since β, ϵ ≥ 0, according to the complementary slackness KKT condition, the equation can be re-written as:β coefficient.To encourage this disentangling property in the inferred β will change the degree of applied learning pressure during training, thereby encouraging different learned representations. We postulated that to learn disentangled representations of the conditionally independent data generative factors v, it is important to set β > 1 to impose a stronger constraint on latent bottleneck than the original VAE. These constraints limit the capacity of z, coupled with the pressure to maximize the log likelihood of the training data x under the model, encouraging the model to learn the most efficient representation of the data. The additional pressure from high β values may create a trade-off between reconstruction fidelity and the quality of disentanglement within the learned latent representations. When the appropriate balance is found between information preservation (reconstruction cost as regularization) and latent channel capacity restriction (β > 1), disentangled representations emerge.Here, different k, respectively, where k represents the number of genes in the dataset. The dimensionality of the latent space learned by the beta-VAE is 256. The relative weighting of the reconstruction loss and regularization loss is 1:4. We apply the Adam with weight decay (AdamW) optimizer with an initial learning rate as 1e−4, the decoupled weight decay as 5e−4 and Adam’s β parameters as 0.9 and 0.999. Moreover, the default running epoch is fixed to 3000, but we use early stopping during the training phase, with which we stop training when the training loss no longer reduces for 50 epochs.In step1, we simulate single-cell by β-VAE. Both the encoder and decoder apply a four-layer perceptron, where each layer is followed by a RELU activation except the last layer of the encoder. For the encoder, the number of neurons in each layer is 2048, 1024, 512 and 512 respectively. While for the decoder, the number of neutrons in each layer is 512, 1024, 2048 and Here we introduce the implementation details of our benchmark approaches. For GAN and cGAN, the generator consists of two fully connected layers, followed by LeakyRELU and RELU activations, respectively. The discriminator is also made up of two fully connected layers, where the first layer is followed by a LeakyRELU activation. We use the Adam optimizer with the initial learning rate of 1e-4 and the betas parameters of 0.5 and 0.999. We train util the loss in the generative and discriminative phases is no longer reduced for 50 epochs, and use the model obtained at this time as the final model for prediction.Calculate cell type proportions. The procedure is identical to the Step 1 deconvolution, we repeated this process to obtain the cell type proportion of each spot in the tissue.s and spot x. When the cell belongs to the spot, the output of the classifier is 1, otherwise the output is 0. Specifically, the input can be represented as Deep forest for spot recommendation. With cell type proportion, we next predicted which cells are contained in each spot. We defined this task as a binary classification problem. We designed a classifier, whose input is the gene expression vectors of both single cell After obtaining the generated data, we needed to map each cell and the spot it belongs to. To improve the accuracy and reduce the complexity of this process, we divided it into two steps. First, we calculated the cell type proportion of each spot, and then predicted which cells are contained in each spot based on this proportion.k-fold cross validation and then concatenated with the original feature vector to be input to the next level of the cascade.We applied multi-Grained Cascade Forest (gcForest), a decision tree ensemble with a cascade structure and further enhanced by multi-grained scanning, to build our classifier. Each level of cascade receives feature information processed by its preceding level and outputs its processing result to the next level. Each level is an ensemble of decision tree forests, i.e., an ensemble of ensembles. We also included completely-random tree forests) to encourage diversity. Given an instance, each forest counts the percentage of different classes of training samples at the leaf node where the concerned instance falls, and then average across all trees in the same forest to produce an estimate of class distribution. The estimated class distribution forms a class vector, which was generated by k to slide the input vector into k-dimensional feature vectors. We then feeded these vectors to n forests and finally produce n two-dimensional vectors. By using multiple sizes k of sliding windows, differently grained feature vectors were generated.To enhance cascade forest, we introduced a procedure of multi-grained scanning. We used sliding windows to scan the raw features. Specially, we used a window with a fixed length of N/16⌋,⌊N/8⌋,⌊N/4⌋} were used for multi-grained scanning. The generated data were used to train a completely-random tree forest containing 100 trees. We concatenated the output of these two forests as the transformed feature vectors, which also acted as the input of cascade forest. The final model was a cascade of cascades, where each cascade consisted of multiple levels each corresponding to a grain of scanning. Each level consisted of 4 completely-random tree forests, each containing 100 trees. In other words, the transformed feature vectors were augmented with the class vector generated by the previous grade, and then were used to train the current grade of cascade forests.The we summarized the overall procedure of gcForest. For the original raw features, three window sizes {⌊Given a test instance, it would obtain its corresponding transformed feature vector through the multi-grained scanning procedure, and then go through the cascade till the last level. The two-dimensional class vectors at the last level were aggregated, and the class with the largest aggregate value was selected to obtain the final prediction result.This decision tree ensemble approach not only had much fewer hyper-parameters than deep neural networks, but also retained the interpretability of tree models. Its model complexity could be automatically determined in a data-dependent manner, which made gcForest work well even on small-scale data.We developed a simple method for predicting the spatial distributions of genes not measured in spatial transcriptomic data which produced by in situ RNA imaging-based technologies. To do this, Bulk2Space used the spatial transcriptomic data as the reference, and generated scRNA-seq data were mapped to the tissue space corresponding to this reference. To eliminate the differences between scRNA-seq data and spatial transcriptomic data caused by different experiment types, an empirical Bayes framework was used to remove the batch effect, so that both sets of data are at the same scale level. Subsequently, the cross-dataset k-nearest neighbor graph of spatial transcriptomic data in scRNA-seq data was computed in the aligned space, and then the predicted whole gene expression profile of each cell of spatial transcriptomic data could be calculated to the mean of its k nearest neighbors in scRNA-seq data.Deep forest is applied for spot recommendation. Specifically, the number of samples used to construct feature discrete bins is set to 200000. If the size of training set is smaller than it, then all training samples will be used. The type of binner used to bin feature values into integer-valued bins is “percentile”, which means each bin will have approximately the same number of distinct feature values. We set the maximum number of cascade layers in the deep forest as 20, and apply 2 estimator in each cascade layer. Gini impurity is used to measure the quality of a split. We have no constraints on the maximum depth of each tree. The training process terminates when the validation performance on the training set does not improve compared against the best validation performance achieved so far to 2 tolerant rounds. And the counting on tolerant rounds is triggered if the performance of a fitted cascade layer does not improve by 1e-5 compared against the best validation performance achieved so far.We also introduce the implementation details of our benchmark approaches. (1) For Logistic Regression (LR), we implement L2 regularization as the additional penalty term to solve the problem of overfitting. We use L-BFGS algorithm as the solver, which uses the Hessian matrix to iteratively optimize the loss function. We fit the model according to the given training data and return the probability estimates on testing set. (2) For Decision Tree (DT), we use the Gini impurity to measure the quality of a split and choose the best split at each node. We don’t set any maximum depth of the tree, so nodes are expanded until all leaves are pure or until all leaves contain less than 2 samples. We build the decision tree classifier from the training set, and then predict class probabilities of the input samples. (3) For Gradient Boosting Decision Tree(GBDT), we set the learning rate as 0.1 and the number of boosting stages to perform as 100. The loss function to be optimized is log loss function, and we choose Friedman MSE to measure the quality of a split. The maximum depth of the individual regression estimators is set to 3. We fit the gradient boosting model on the training set and use the trained model to make predictions on testing set. (4) For Multilayer Perceptron(MLP), we apply a two-layer perceptron, where each layer is followed by a batch normalization, a RELU activation, and a dropout layer with the probability of element zeroing as 0.1. We use the Adam optimizer with the initial learning rate of 1e-4 and the betas parameters of 0.9 and 0.999. We train until the loss is no longer reduced for 30 epochs, and use the model obtained at this time as the final model for prediction. (5) For DeepGBM, we set the number of tree groups to 100. The dimension of leaf embedding for a tree group is set to 20. The structure of the distilled NN model is a fully connected network with “100-100-100-50” hidden layers. We adopt the feature selection in each tree group, where we first sort the features according to the information gain, and the top 128 of them are selected as the inputs of distilled NN model. We use the Adam with weight decay (AdamW) optimizer with an initial learning rate as 2e-3, the decoupled weight decay as 1e-6, and Adam’s betas parameters as 0.9 and 0.999. We train until the model reaches the highest ROC-AUC score, and use it for prediction.Simulated bulk data and the single-cell reference were generated from same datasets (paired simulations).46 (“GSE92495”), brain61 (“GSE103723”), kidney62 (“GSE121862”), liver63 (“GSE124395”), and lung64 (“GSE130148”). Five mice scRNA-seq datasets including brain65 (“GSE60361”), kidney66 (“GSE119531”), lung67 (“GSE127465”), pancreas68 (“GSE84133”), and testis69 (“GSE112393”).Ten scRNA-seq datasets were applied to benchmark our method, including human and mouse primary tissues. Five human scRNA-seq datasets including peripheral bloodThe simulated data were derived from the above 10 scRNA-seq datasets. We randomly divided the scRNA-seq data into two parts, one was treated as the single-cell reference data_2) and the other (data_1) for the construction of bulk transcriptome data via aggregating all the single-cell gene expression profiles. Considering the cell composition of bulk RNA-seq data varies greatly in the natural situation, for each data_1, we further changed the cell-type proportion and synthesized 3 corresponding bulk transcriptome data with different cell compositions. In total, 30 paired simulated data were synthesized in this study. The detailed description of the experimental design was summarized in Supplementary Data  and the a, Generative adversarial networks (GAN), b, conditional generative adversarial networks (CGAN). The generator consists of two fully connected layers, followed by LeakyRELU and RELU activations respectively. The discriminator is also made up of two fully connected layers, where the first layer is followed by a LeakyRELU activation. We use the Adam optimizer with the initial learning rate of 1e-4 and the betas parameters of 0.5 and 0.999. We train until the loss in the generative and discriminative phases is no longer reduced for 50 epochs, and use the model obtained at this time as the final model for prediction.2.Simulated bulk data and the single-cell reference were generated from different datasets (unpaired simulations).Pearson correlation coefficient (PCC), Spearman’s rank correlation coefficient (SRCC), and root mean squared error (RMSE) were used to assess the similarity of the gene expression profile between scRNA-seq data reference and synthetic bulk transcriptome data.70 (“GSE81076”), 1 CelSeq271 (“GSE85241”), 1 Fluidigm C172 (“GSE86469”), 4 inDrops68 (“GSE84133”), and 1 SMART-Seq273 (E-MTAB-5061).Eight human pancreas scRNA-seq datasets from different resources were also applied to benchmark our method, including 1 CelSeqThe simulated data were derived from the above 8 scRNA-seq datasets. We randomly selected one as the single-cell reference and another dataset from different resources as bulk transcriptome data. The detailed description of the experimental design was summarized in Supplementary Data a, Generative adversarial networks (GAN). b, conditional generative adversarial networks (CGAN). The model details were described above. c, bMIND41. We followed the guidelines on the bMIND GitHub repository: https://github.com/randel/MIND. We set the cell type proportion parameter “frac” to the output value of Bulk2Space to ensure the generated gene expression profile comparability.The benchmark metrics were described above.C,x is the maximum gene expression value of scRNA-seq data reference.we evaluated the robustness of Bulk2space by introducing two kinds of noise: cell type noise and gene expression noise. For cell type noise, we randomly altered the type of cells with the ratio of 0.01, 0.02, 0.04, 0.08, 0.1, 0.2, 0.3, 0.4, 0.5, 0.7, and 0.9. For gene expression noise, we firstly constructed a noise expression profile We next constructed synthetic expression matrix by combining noise expression profile with scRNA-seq data reference, and the ratio of gene expression-altered cells remains 0.01, 0.02, 0.04, 0.08, 0.1, 0.2, 0.3, 0.4, 0.5, 0.7, and 0.9. PCC, SRCC and RMSE between the synthetic expression matrix and constructed bulk RNA-seq data were used to evaluate performance.Spatial barcoding-based dataEighteen datasets metioned above were applied to benchmark our method. 10 datasets were applied to construct single-cell data and spatial reference from same datasets, and other 8 datasets were applied to construct single-cell data and spatial reference from different datasets.Starting from scRNA-seq data reference, we randomly chose 10 cells from it and aggregated their transcriptomic profiles as a spot of pseudo spatial transcriptomic data. The spot with over 25000 UMI counts would be sampled down to 20000 UMI counts to better meet the true situation. We also constructed pseudo spatial transcriptomic data with 100, 200, 500, 1000, and 5000 spot numbers to simulate true spatial transcriptomics data produced by different spatial barcoding technologies. Besides, the simulation that the scRNA-seq and spatial datasets are from different sources was also considered. The detailed description of the experimental design was summarized in Supplementary Data a, Logistic Regression (LR). We implement L2 regularization as the additional penalty term to solve the problem of overfitting. We use L-BFGS algorithm as the solver, which uses the Hessian matrix to iteratively optimize the loss function. We fit the model according to the given training data and return the probability estimates on testing set. b, Decision Tree (DT). We use the Gini impurity to measure the quality of a split and choose the best split at each node. We don’t set any maximum depth of the tree, so nodes are expanded until all leaves are pure or until all leaves contain less than 2 samples. We build the decision tree classifier from the training set, and then predict class probabilities of the input samples. c, Gradient Boosting Decision Tree (GBDT). We set the learning rate as 0.1 and the number of boosting stages to perform as 100. The loss function to be optimized is log loss function, and we choose Friedman MSE to measure the quality of a split. The maximum depth of the individual regression estimators is set to 3. We fit the gradient boosting model on the training set and use the trained model to make prediction on testing set. d, Multilayer Perceptron (MLP). We apply a two-layer perceptron, where each layer is followed by a batch normalization, a RELU activation, and a dropout layer with the probability of element zeroing as 0.1. We use the Adam optimizer with the initial learning rate of 1e-4 and the betas parameters of 0.9 and 0.999. We train until the loss is no longer reduced for 30 epochs, and use the model obtained at this time as the final model for prediction. e, DeepGBM. We set the number of tree groups to 100. The dimension of leaf embeddin for a tree group is set to 20. The structure of the distilled NN model is a fully connected networks with “100-100-100-50” hidden layers. We adopt the feature selection in each tree group, where we first sort the features according to the information gain, and the top 128 of them are selected as the inputs of distilled NN model. We use the Adam with weight decay (AdamW) optimizer with an initial learning rate as 2e-3, the decoupled weight decay as 1e-6, and Adam’s betas parameters as 0.9 and 0.999. We train until the model reach the highest ROC-AUC score, and use it for prediction. f, RCTD34. We followed the guidelines on the RCTD GitHub repository: https://github.com/dmcable/spacexr. We set the parameter doublet_mode = ‘full’. g, spatialDWLS35. We followed the guidelines on the spatialDWLS GitHub repository: https://github.com/rdong08/spatialDWLS_dataset/tree/main/codes. We set the parameter n_cell = 20. h, stereoscope36. We followed the guidelines on the stereoscope GitHub repository: https://github.com/almaan/stereoscope. We set the parameter sc epochs = 10000, st epochs = 10000. i, SPOTlight37. We followed the guidelines on the SPOTlight GitHub repository: https://github.com/MarcElosua/SPOTlight. We set the parameter n_cells = 75.2.Image-based in situ hybridization dataPearson correlation coefficient (PCC), Spearman’s rank correlation coefficient (SRCC), and root mean squared error (RMSE) were used to assess the similarity of the gene expression profile per spot between the predict result and ground truth. Due to RCTD, spatialDWLS, stereoscope, and SPOTlight could not obtain gene expression profiles for each spot, we calculated gene signature matrix of each cell type based on single-cell reference, and the product of the predicted proportions of each cell type and the gene signature matrix of each cell type was regarded as the gene expression profile of each spot.GSE113576”) and MERFISH data (Bregma +0.26) (image-based reference) from the same laboratory43 were applied to test the performance of the Bulk2Space algorithm for the second spatial mapping strategy. We also applied another mouse hypothalamus scRNA-seq data44 (“GSE87544”) from different source as single-cell reference to confirm the robustness of Bulk2Space.A mouse hypothalamus scRNA-seq data (“Pearson correlation coefficient (PCC) was used to assess the similarity of the gene expression profile between the predict result and ground truth. We took two strategies, five-fold cross validation and leave-one-out cross validation, to validate performance of Bulk2Space. In five-fold cross validation, we random split 150 target genes identified in MERFISH into five folds using R package caret (version 6.0–92), a split of 80% for reference and 20% for validation. In leave-one-out cross validation, 149 were used as reference genes and and one was used for validation.74 (“GSE119340”) were applied to evaluate the performance of the deconvolution step of Bulk2Space.Three paired mouse liver bulk and single-cell datasets12 and scRNA-seq data45 were downloaded from the Seurat website: https://satijalab.org/seurat/articles/spatial_vignette.html were applied to evaluate the performance of the spatial mapping step of Bulk2Space on real single-cell data and real spatial data. We down sampled Slide-seq v2 data to 5000 spots to speed the spatial mapping step. For Bulk2Space, we set the parameter k = 2 and top_marker_num = 100, all other parameter followed the default values. For Seurat, we followed the standard analysis workflow on the Seurat website and set the parameter resolution = 0.3 to perform unsupervised clustering.The mouse hippocampus Slide-seq v246 (“GSE92495”) scRNA-seq data. The construction of the single-cell reference and bulk transcriptome data was the same as mentioned above. We further evaluated the spatial mapping results using the pancreatic ductal adenocarcinoma (PDAC) dataset47 and the human melanoma dataset49 with 3-time repetitions. For Bulk2Space, all parameters followed the default values.We conducted 100-time repetitions on the deconvolution step of Bulk2Space to evaluate the robustness of β-VAE using the human peripheral blood46 (“GSE92495”) scRNA-seq data into two parts, one was treated as the single-cell reference and the other for the construction of bulk transcriptome data via aggregating all the single-cell gene expression profiles. For the single-cell reference, we followed the scRNA-seq data analysis workflow on the Seurat website: https://satijalab.org/seurat/articles/pbmc3k_tutorial.html to get 5 “clustering spaces” using “FindClusters” function with the parameter resolution = 0.2. For Bulk2Space, all parameters followed the default values.We further evaluated the performance of Bulk2Space without providing cell type information. We randomly divided the human peripheral bloodGSE72056”) by Tirosh48 et al. was used as the single-cell reference, and two consecutive slices of the ST data by Thrane49 et al. were used as spatial reference (slice 1) and synthesized bulk data (slice 2) , respectively. For Bulk2Space, we set the parameter epoch_num = 3500, k = 10, and top_marker_num = 500, all other parameters followed the default values.The scRNA-seq data .We firstly evaluated the expression correlation of marker genes for five major cell types between generated single-cell expression profiles from synthesized bulk data (slice 2) and ground truth. We applied “FindAllMarkers” function of Seurat (version 4.0.4)https://metascape.org) to investigate the biological functions.For B cells spatial heterogeneity analysis, we determined two spatial areas (lymphoid area and tumor area) based on histological annotation firstly. Then, differentially expressed genes analysis between B cells from different areas was applied by the “FindAllMarkers” function with the parameter logfc.threshold = 0.25. For these differentially expressed genes, we further performed the pathway enrichment analysis using the Metascape  and synthesized bulk data  , respectively. For Bulk2Space, we set the parameter epoch_num = 3500, k = 10, and top_marker_num = 500, all other parameters followed the default values. The evaluation procedure of the marker gene expression correlation between Bulk2Space results and slices was same as it in the human melanoma dataset analysis.Bulk2Space was performed for another PDAC dataset50 et al. were downloaded from “GSE171485”. We firstly applied the PDAC-A scRNA-seq data by Moncada47 et al. as the single-cell reference to deconvolute pancreatic adjacent tissues bulk data and pancreatic cancer tissues bulk data respectively. We then applied the PDAC-A ST1 by Moncada47 et al. as the spatial reference and performed spatial mapping step for the generated single-cell gene profiles from pancreatic cancer tissues bulk data. For Bulk2Space, we set the parameter epoch_num = 3500, k = 10, and top_marker_num = 200, all other parameters followed the default values.The pancreatic adjacent tissues and pancreatic cancer tissues bulk data by Wu52 and two tissue sections (anterior section 1 and posterior section 1) sequenced by 10X Visium as the single-cell reference and spatial references, respectively. For Bulk2Space, we set the parameter epoch_num = 3500 and top_marker_num = 300, all other parameters followed the default values.The mouse isocortex bulk data was produced by Spatial-seq (see Methods). We applied a mouse primary visual cortex scRNA-seq dataGSE113576”) and MERFISH data (Bregma −0.04) by Moffitt43 et al. as the single-cell reference and spatial reference, respectively. For Bulk2Space, we set the parameter epoch_num = 3500 and top_marker_num = 500, all other parameters followed the default values. For those ambiguous cells in MERFISH data, we re-annotated their cell type based on the whole gene expression profiles predicted by Bulk2Space.The mouse hypothalamus bulk data was produced by Spatial-seq (see Methods). We applied a mouse hypothalamus scRNA-seq data . We selected the human prostate cancer scRNA-seq data by Wu54 et al. as the single-cell reference, and three ST data from different tissue section location as spatial references . For Bulk2Space, we set the parameter epoch_num = 3500, k = 10, and top_marker_num = 500, all other parameters followed the default values. We then compared the distribution of various cell types in these three different tissue regions.The human prostate cancer bulk data was downloaded from TCGA  were selected as the basic units (2×3 plates) of each layer. Each well in the barcoding array can be labeled as barcode . Magnetic beads coated with carboxyl group  were distributed into each well for barcode synthesis. There were three rounds of barcode extension reactions. In the first round, 5’ amino-modified barcoded oligonucleotides (barcode Xi) were conjugated to the beads. In the second round of extension reaction, barcoded oligonucleotides (barcode Yj) which had a sequence of bases at the 5’ end complementary to the 3’ end of barcode Xi were linked to the end of barcode Xi by PCR. Similarly, in the third round of reaction, barcode sequences containing a unique molecular identifier (UMI) and a polyT tail (barcode Zk) were extended to barcode Yj by PCR. All oligonucleotides were purchased from Sangon Biotech (Shanghai) Co., Ltd. This method only needs 144 (48×3) different barcodes to theoretically generate magnetic beads with 483 distinct kinds of magnetic beads with known sequences. More importantly, the entire synthesis process was serialized and multiplexed, which can be accomplished with the help of arrayed pipettes or liquid workstations, rather than synthesizing the magnetic beads well by well. The spatially barcoded beads can be used in many areas, such as multiplexed labeling of tissue samples or even single cells.A virtual 48×48×48 three-dimensional well array (barcoding array) was constructed in the https://portal.brain-map.org/). After spatial registration, the anatomical regions of the mouse brain were delineated and annotated. The outlines, dissection sequences, and collectors of the brain regions were specified from the annotated data and then imported to an LCM instrument . LCM is a microscope-guided powerful cutting system incorporating UV light for contact- and contamination-free isolation of areas of interest from tissue sections15. Brain regions were dissected from the tissue by LCM according to the imported files and fell into the collector loaded with barcoded beads in advance. Spatial-seq has the potential to achieve spatially resolved whole transcriptome sequencing of a large number of single cells.Three wild-type adult C57BL/6 J mice  aged 8–10 weeks were used for Spatial-seq experiments. The environmental conditions in the mouse facility were: 12 h light and 12 h dark cycle (light on from 8:00 a.m. to 8:00 p.m.), light intensity range of 15–20 lux, temperature range of 22–26 °C, humidity range of 40–70%, and free access to food and water. The use and care of the mice were in accordance with the guidelines of the Animal Advisory Committee of Zhejiang University and the US National Institutes of Health Guidelines for the Care and Use of Laboratory Animals. All procedures were approved by the Animal Advisory Committee of Zhejiang University. The mouse brain was sliced into 14-μm sections from the coronal and sagittal directions. Each tissue slice was registered to a reference brain template provided by the Allen Brain Atlas , LiCl , 10% SDS solution , EDTA , 0.5 M DTT solution , and water . Each well was loaded with lysis buffer. The tissue was lysed on ice for 12 min. The beads were then washed and transferred for reverse transcription (RT), The captured mRNA was reverse transcribed using PrimeScript II Reverse Transcriptase .to construct cDNA libraries following the guidance of Illumina Nextera XT DNA Library Preparation Kits. A paired-end sequencing was conducted to decode the spatial barcode in the 3’ end and detect RNA species in the 5’ end of the cDNA.http://www.bioinformatics.babraham.ac.uk/projects/fastqc/). The derived RNA-seq data were fragmented into lots of files based on the spatial barcodes. The digital gene expression matrix for each barcode was retrieved follow the Drop-seq sequence alignment cookbook.FastQC was utilized for quality control of the RNA-seq data .In this study, 152 simulated datasets , 13 biological datasets, and 2 experimental datasets were used to evaluate the Bulk2Space algorithm. Unannotated, ambiguous, or low quality-cells were excluded from the analysis. Pearson correlation coefficient, Spearman’s rank correlation coefficient, and root mean squared error were used to compare the performance between different methods. For paired data simulations, single cells were randomly selected to synthesize the reference and the test set. For unpaired data simulations, single-cell profiles were randomly selected to synthesize the reference and the test set. The Investigators were not blinded to allocation during experiments and outcome assessment.Further information on research design is available in the Supplementary informationPeer Review FileDescription of Additional Supplementary FilesSupplementary DatasetsReporting Summary


Drug repositioning allows expedited discovery of new applications for existing compounds, but re-screening vast compound libraries is often prohibitively expensive. “Connectivity mapping” is a process that links drugs to diseases by identifying compounds whose impact on expression in a collection of cells reverses the disease’s impact on expression in disease-relevant tissues. The LINCS project has expanded the universe of compounds and cells for which data are available, but even with this effort, many clinically useful combinations are missing. To evaluate the possibility of repurposing drugs despite missing data, we compared collaborative filtering using either neighborhood-based or SVD imputation methods to two naive approaches via cross-validation. Methods were evaluated for their ability to predict drug connectivity despite missing data. Predictions improved when cell type was taken into account. Neighborhood collaborative filtering was the most successful method, with the best improvements in non-immortalized primary cells. We also explored which classes of compounds are most and least reliant on cell type for accurate imputation. We conclude that even for cells in which drug responses have not been fully characterized, it is possible to identify unassayed drugs that reverse in those cells the expression signatures observed in disease. Connectivity mapping [ mapping  refers t mapping –3.More recently, the LINCS Consortium dramatically scaled up the connectivity map database using the L1000 assay, which measures expression of 978 genes at a much lower cost. The LINCS connectivity map includes a much larger set of compounds, small molecules, and cellular perturbations across a wider range of cell types . Howeverin vivo. For a precision medicine approach to connectivity, particularly outside the realm of oncology, the ability to identify drugs that reverse a patient’s disease signature even in the absence of connectivity data for a given cell/drug combination will improve scalability and relevance. We therefore aim to determine whether accurate imputation of context-specific connectivity is possible despite missing data.Further, gene expression profiles in primary cells are a relatively small part of the LINCS data set, and profiling all desirable cell types and states is impractical even with more efficient assays. Thus, candidate drugs identified through connectivity mapping may have very different effects The first step is imputing expression values for drug/cell combinations that lack experimental data. Since the early days of microarrays, there have been efforts to impute missing expression values caused by array defects or hybridization issues . The naïve approach, averaging over expression values for a given gene in other samples in the data set, was quickly improved upon by more principled methods, including k-nearest neighbors and SVD , local lHowever, nearly all of these approaches address a different problem—one in which there is a limited fraction (e.g. under 20%) of missing genes for a given sample, and in which the missing data points are not correlated across samples. A few approaches try to fit some characteristics of the random missing data, such as the observed histogram of the fraction of missing genes per sample . Few of et al. [Explicitly imputing connectivity for unassayed drugs and cells is thus a distinct problem. Hodos, et al.  first deTo assess our ability to determine connectivity with missing data, we need a data set where we know the right answers. We create two such data sets by taking a complete subset of the LINCS connectivity data and a more realistic sparse subset in which approximately 75% of the drug/cell pairs are missing. Perturbations in LINCS include gene overexpression or inhibition, but for the purposes of this evaluation, we choose perturbations reflecting treatment with named compounds or chemicals. We evaluate performance on each data set through five-fold cross-validation to assess how well connectivity queries can produce the same results with missing data as they would with the full data set. Specifically, given a drug-cell combination of interest for which the expression profile is unavailable, we ask how well we can impute drug connectivity for this drug-cell pair, and whether we can do so more accurately by taking cell type into account.C be a set of c cell types, D be a collection of d drugs or cellular perturbations, and N be a set of n genes. We will refer to individual drugs or cells, such as the ith of |D| drugs or the jth of |C| cells, as di and cj, respectively. We start with a 3-dimensional matrix or tensor, M, containing gene expression profiles of all genes in N in a subset of the drug/cell combinations (D × C). These expression values reflect expression in the indicated cell treated with the indicated drug, compared to expression in the same cell without any treatment. Note that M may be sparse, but the expression profiles are all-or-nothing; if we have any expression data for a cell/drug combination, we have values for all n genes in the treated cell compared to the untreated cell.Let As described in the paper introducing the initial L1000 connectivity data set , these equery signature for a particular phenotypic state is defined to consist of two gene sets, one containing the most up-regulated, and the other the most down-regulated, genes in that state compared to a suitable control. So for example, a query signature for prostate cancer might consist of the 50 most up- and down-regulated genes in tumors from prostate cancer patients compared to adjacent normal tissue. Following the notation of [k most upregulated genes in the query comparison, and k most downregulated genes for the same comparison.A ation of , we use c treated with drug d compared to cell c without drug exposure, we compute the weighted connectivity score (WCS) as:up and ESdown refer to the weighted Kolmogorov-Smirnov enrichment statistic (ES) described in [SX in reference profile A connectivity map query is performed in the following way, as described in more detail in . Given tribed in  that capc and drug d:To further enable comparisons across cells and drugs, we can compute the normalized connectivity scores (NCS) as in , by meanOur data are derived from the LINCS data published in the Gene Expression Omnibus (GEO)  as GSE70For assessment purposes, we created two data sets: a small, complete data set, and a larger, sparse data set. The complete data set contains 12 cell types: 8 cancer cell lines, A375, A549, HCC515, HEPG2, HT29, MCF7, PC3, and VCAP; HA1E, an immortalized normal kidney cell line; one stem cell line, ASC , and two types of primary neural cells: NPC  and NEU (fully differentiated neurons). To create a complete and interpretable data set, we chose 450 drugs with “real” names  and for which there is expression data for all 12 of the cell types above.The sparse data set includes 80 cell types: 60 cancer cell lines, 6 immortalized normal cell lines, 4 stem cell lines, and 10 primary cell types. : A good baseline prediction of drug di’s performance in cell cj might be simply to look at what drug di does to a cell, regardless of what type of cell it is. Assume that we have expression profiles for drug di on other cell types. By taking the median of the expression values of that drug over all the other cells for which we do have data Median of Medians : One approach to collaborative filtering is to rely on the closest neighbors of a particular sample as a model. An average, weighted by similarity of the neighbors’ ratings, approximates the rating for the sample of interest. A critical change was necessary to use this approach with our data, because each “rating” in the connectivity matrix is actually a vector of gene expression values. To avoid loss of information, we view the gene expression values as a multi-part rating of the same item. In the user/movie-rating metaphor, these values would represent a rating that perhaps specified an overall rating, as well as ratings of the movie’s acting, cinematography, and soundtrack.M by concatenating, for each drug, expression values for all genes in the first cell, the second cell, etc. We call this reshaped matrix R. The rrecsys package then mean-centers each row and calculates similarities between drugs (rows) by taking the adjusted cosine similarity [Because these methods are intended for two-dimensional matrices, we create one from our three dimensional tensor milarity  between x “neighbors” of the row containing the missing value : The goal of this approach is to account for latent subclasses within the drugs or cells. We used the FunkSVD R package, which applies stochastic gradient descent SVD optimization to build an approximation of an input matrix. This specific methodology was shown to be particularly effective in predicting Netflix movie ratings [R defined above. ratings . The Fun ratings . Note th ratings . BecauseU and V with singular values folded into those matrices. The parameters of this function determine the output rank of the approximation. For our purposes we used rank parameter k = 55.  of cross validation data sets for both the complete and sparse matrices. We summarize our results across those five runs. Both the data sets and the folds used for cross validation in each run are provided with the supporting data.Once we have a predicted expression profile for a withheld drug-cell combination, we must assess how accurate our prediction is through some comparison to the actual withheld expression profile. Since our aim is to infer connectivity for cell-drug pairs for which we lack data, an informative evaluation method would be to compare the connectivity results from the true data with those obtained using imputed data.There are two parts of a list of drugs returned by a connectivity query that are of interest. Drugs with the most positive connectivity scores are drugs that replicate the query signature; these are sometimes used to identify similar drugs, or to find compounds that might cause a similar change to that of the query expression profile as an adverse event. Drugs with the most negative connectivity scores are those that reverse the observed query signature; these are candidate therapeutics for an observed disease signature. Accordingly, we want to assess how well the most-positive, or most-negative, connectivity results from the imputed data match those from the withheld true data.r is the result rank, ϕ is the normal distribution of the form ϕ, and ϵ is a parameter with value between 0 and 1 controlling the “aggressiveness” of the curve.To do this, we use the Weighted Spearman rank correlation (WSpe) measure, defined by . We use ϵ = 0.01, which applies weights of significant magnitude to approximately the top 20 results, after which weights diminish towards zero. We tested the effect of doubling or halving ϵ but saw minimal changes in the results . Combining the imputed values over all folds yields a list of all the drugs ranked by their imputed WCS values in MCF7 cells. We then compare this imputed profile to the true profile using the weighted Spearman rank correlation metric defined above.For an example of how scoring works, suppose that M includes data on the impact of the Beyond comparison to true profiles, we can evaluate our performance by assessing the connectivity of a drug’s expression profile to other drugs within the same perturbagen class. A perturbagen class (PCL) is a group of drugs that share a mechanism of action or target genes. PCLs are defined by published literature and further refined by connectivity analysis to yield 171 classes, as described in more detail in . PCL memFor a given compound, a query signature reflecting expression changes caused by treatment of cells with that compound is expected to return strong positive connectivity between that drug and others in the same PCLs.To evaluate an imputation method, we can construct a query from an imputed signature and determine if drugs in the same PCL set are over-represented towards the top of the returned list, expressing strong positive connectivity.d, to create a query signature with the top and bottom 50 genes . We theWe adapt gene set enrichment analysis tools , 24 to fin the chosen query matrix, there are 132 drugs of the 450 in the complete data set that are in the remaining perturbagen classes. In the sparse data set, 334 of the 1330 drugs are in PCLs.For this analysis, we require a minimum of three drugs per PCL. After removing drug classes with no more than 2 drugs An enrichment score (ES) is calculated as described in Section 2.2, weighted by connectivity scores from the query results. In this context, an ES captures enrichment of a PCL set in the connectivity result of a drug that is a member of that set. The normalized connectivity score (NCS) is then calculated  to account for the varying set sizes. Significance of enrichment is determined by comparing the observed NCS to the NCS of 1,000 random permutations of the connectivity result. The fraction of the absolute value of the permuted NCS greater than, and thus stronger, than the absolute value of the observed NCS yields the normalized p-value . . We measure the percentage of drugs significantly enriched in their PCL for every PCL/cell combination to assess our ability to impute connectivity query results even in the absence of experimental data, as well as to estimate the amount of data needed.With known drug classes, we can also assess how well we impute connectivity query results To assess accuracy, we performed connectivity queries with query signatures containing the most dysregulated genes for each drug in the treated cell compared to untreated controls. Specifically, the query signatures consist of the 50 most up- and down-regulated genes for a given drug. Positive connectivity scores identify the drugs that induce expression changes most similar to those of the query drug; negative connectivity scores identify drugs whose effects on a cell reverse the effect of the query drug.The average weighted Spearman rank correlations (WSpe) over all drugs between the true and predicted connectivity results for the complete data set appear in These figures show that for negative connectivity, the most commonly envisioned use case of the connectivity map, there is robust improvement in prediction under almost all methods, with neighborhood collaborative filtering either best or essentially tied with MoM for best in all cells. Neighborhood collaborative filtering’s improvements are especially large , with the majority of NCS values clustered well above zero. Neighborhood collaborative filtering has a slightly higher median than all other methods and greater NCS values overall, proving to be the most robust and consistent method to be evaluated.We further generated a complete version of the sparse matrix (where 75% of the cell/drug combinations were missing) using only imputed data, as described in Section 2.5.2. We then assessed our ability to find related drugs within the same PCL using imputed query profiles against this completely imputed matrix.Of the drug/cell/PCL combinations, 53% have “drug set enrichment analysis” p-values (as defined in Section 2.5.1) less than 0.05, meaning that in the majority of drug and cell combinations evaluated, connectivity query results are correctly imputed by the neighborhood collaborative filtering method, given a sparse matrix of experimental data. The approach was best at accurately detecting strong positive connectivity in most of the drug sets in NPC, SKB, PHH and NEU cells, all of which had data for at least 41% of the compounds. In cells containing data for 5% or less of the compounds, the percentage of significant NCS values drops, consistent with the results noted above for positive and negative weighted connectivity correlations. This is true across all cell types assessed, with cells containing less than 5% of the 1330 drugs assayed showing a lower percentage of statistically significant NCS values.Similarly, drug classes with the most drugs tend be well imputed across the board, suggesting the likelihood that in such cases the “neighborhood” is well populated by related drugs. Drug classes for which imputation is better with neighborhood collaborative filtering include aurora kinase inhibitors, FLT3 inhibitors, and a number of steroid/hormone classes . Classes where tissue-agnostic methods were better included retinoid receptor agonists and serotonin receptor antagonists. . These surprising yet plausible connections, along with more expected ones , were discoverable only through predictive methods.The most connected compounds ophrenia  and Alzhophrenia . Bosentaophrenia ; mouse mWe next queried the same database with the signature of differentially expressed genes from a microarray study that compared left ventricular myocardial samples from ischemic cardiomyopathy patients to controls . There We have demonstrated that context-specific connectivity data can be used to infer missing connectivity data and can be reliably used to connect query signatures to drugs that may affect them even when those drugs have not been assayed in the relevant cells. This has applications for the full LINCS data set, in which many cell types have data for just a few tens of compounds, and even beyond. We have also shown that using cell-specific information does not always improve imputation of connectivity when under 5% of the drugs have been profiled in the cell—or in other words, when there isn’t much data to work from. An important direction for future work is to better understand the impact of the distribution of compounds needed for robust prediction across sparse matrices of different sizes and compositions.et al. addressing the same problem [et al. used a two-dimensional tensor completion method. They combined data from all possible ways of mapping the three dimensions into two, but then heavily downweighted one of them, essentially averaging the others.After completion of this work, we became aware of a paper by Hodos,  problem . There a problem , uses diDespite these differences, we see our work as a valuable complement to their study. We verified that cell type crucially influences connectivity results, and we found that having experimental data for at least 10% of the drugs appears to be enough for our cell-specific methods to out-perform the naive tissue-agnostic approach. We also confirmed that there is no one imputation method that performed best in all cases; performance relies on the specific cells involved.An important novel contribution of ours is viewing the problem via the collaborative filtering framework, which we expect will suggest a host of additional methods to be tried in future work. Another difference appears in our interpretations of which perturbagen classes are more amenable to cell-specific or cell-agnostic imputation methods. We saw particular success with classes of kinase inhibitors and hormonal regulators. We also uniquely identified improved tissue-specific imputation in primary cells, demonstrating that using cell-specific methods and data will be especially important for extending connectivity methods beyond oncology. We expect that a detailed examination of specific results from both studies will provide additional information on best practices for future connectivity analyses.et al. is a good attempt in this direction, but current tensor completion methods do not generally handle missing data in all of one of the dimensions of the tensor . New approaches, including additional machine learning methods, might be more successful.Despite the successes of both studies, there is considerable room for improvement using new imputation methods. We found that the neighborhood collaborative filtering approach was most often the best method in this study. That said, there is the possibility of improving on SVD by using higher-order methods that better capture the three-dimensional structure of the data. The tensor formulation of Hodos, We also showed examples where queries based on actual expression data from patients were able to identify compounds that were not tested in those cells and that would not have been discovered without these predictive approaches. Of the four compounds highlighted as new discoveries in our example disease queries, only givinostat would have been among the top 10% of compounds if querying the “summary” profile, an average of just the assayed cells that is typically used when querying through the online tools provided by LINCS. The other compounds we highlighted would only have been identifiable through cell-specific imputation.Finally, we conclusively emphasize that considering cell type is critical for accurate connectivity mapping. This point is also apparent in prior work with multiple different breast cancer cell lines , but it S1 File(PDF)Click here for additional data file.