gene coordinates of cell type genes were obtained based on the grch37. 13 genome annotation. for snp data ( names, locations and linkage - related information ), the 1000 genomes european reference ( grch37 ) was used, as previously described. only snps from the hapmap 3 project were included in the analysis. for identification of snps in the vicinity of cell type genes, we used a window size of 100, 000 base pairs. genes from x and y chromosomes, as well as human leukocyte antigen genes, were excluded because of their unusual genetic architecture and linkage patterns. for linkage disequilibrium score calculation, a 1 cm window was used. significance of the link between a phenotype and a cell type was calculated using ldsc. p values yielded by ldsc were corrected for multiple testing for every disease tested using the benjamini – hochberg correction procedure. as a negative control, the analysis was performed with a gwas of depression and no cell types were found to be significant ( supplementary fig. 7 ). the numbers of cases and controls per gwas study were as follows: n = 2, 668 cases and 8, 591 controls for ipf; n = 35, 735 cases and 222, 076 controls for copd; n = 11, 273 cases and 55, 483 controls for lung adenocarcinoma; n = 321, 047 individuals for lung function; n = 88, 486 cases and 447, 859 controls for asthma; and n = 113, 769 cases and 208, 811 controls for depression ( used as negative control ). to enable deconvolution of bulk expression data on the basis of the hlca, hlca cell type signature matrices were generated. one generic-purpose signature matrix was created per sublocation of the respiratory system ( that is, one parenchyma, one airway and one nose tissue matrix; supplementary table 10 ). additionally, a script to generate custom reference sets from the hlca data is provided together with the hlca code on github ( https: / / github. com / lungcellatlas / hlca ) to tailor the deconvolution signature matrix to any specific research question. cell types were included in the bulk deconvolution signature matrix on the basis of cell proportions ( constituting > 2 % of cells within samples of the corresponding tissue in the hlca core ). in addition, cell types were merged when they were deemed too transcriptionally similar. for each included cell type, 200 cells were randomly sampled from the hlca core, while all cells were included for cell types with fewer than 200 cells present in the hlca core. cells were sampled from the matching anatomical location ( for example, nose t cells rather than parenchymal t cells were used for the nose signature matrix ). signature matrices were constructed using cibersortx ( version 1. 0 ) according to default settings, and no cross - platform batch correction was applied. the reference data were optimized by deconvolution of pseudo - bulk samples constructed from the hlca core data, assessing deconvolution performance per included cell type based on the correlation of predicted proportions with ground truth composition ( supplementary fig. 8a ). the following cell types were included in the deconvolution: endothelial cell arterial, endothelial cell capillary, lymphatic endothelial cell, basal and secretory ( merged ), multiciliated lineage, at2, b cell lineage, innate lymphoid cell ( ilc ) natural killer and t cell lineage ( merged ), dendritic cells, alveol ar macrophages, interstitial macrophages, mast cells, fibroblast lineage, smooth muscle, endothelial cell venous and monocytes ( for the parenchyma ); basal resting and suprabasal ( merged ), multiciliated lineage, club, goblet, dendritic cells, hillock like and t cell lineage ( for the nose ); and endothelial cell venous, cd4 t cells, fibroblasts, smooth muscle, basal and secretory ( merged ), multiciliated lineage, endothelial cell capillary, interstitial macrophages, b cell lineage, natural killer cells, cd8 t cells, dendritic cells, alveol ar macrophages, mast cells and monocytes ( for the airway ). capillary endothelial cells and interstitial macrophages ( airway ) were excluded from statistical testing due to poor performance in the benchmark. venous endothelial cells and monocytes ( parenchyma ), hillock - like cells and t cell lineage cells ( nose ) and b cell lineage cells, natural killer cells, cd8 t cells, dendritic cells, alveol ar macrophages, mast cells and monocytes ( airways ) were excluded from statistical testing due to > 60 % zero proportions. the parenchymal signature matrix was used to deconvolve rna expression data of samples from the lung tissue database ( geo accession number gse23546 ) using only lung tissue samples from patients with copd gold stages 3 and 4 ( n = 27 and 56, respectively ) and matched controls ( n = 281 ). the lung tissue database dataset was run on the rosetta / merck human rsta custom affymetrix 2. 0 microarray platform ( hursta - 2a520709; gpl10379 ). as this platform has multiple probe sets for each gene, we focused on the probe sets that were derived from curate d refseq records ( with nm _ accession prefixes ) when present to maximize the accuracy of the deconvolution. where genes did not have probe sets based on curate d refseq records or had multiple probe sets mapping to curate d refseq records, the probe set with the highest average microarray intensity across samples was selected. quantile normalization of the data and subsequent deconvolution were performed using cibersortx. a wilcoxon rank - sum test between control and gold stage 3 / 4 samples was performed to identify statistically significant compositional changes in advanced - stage copd compared with control tissue. gold 3 / 4 and control samples were matched for age and smoking history. cell types with > 60 % of samples predicted to have a proportion of zero were excluded from the wilcoxon test, as the high number of tied ranks ( zeros in both groups ) would result in inflate d p values. p values were multiple testing corrected using the benjamini – hochberg procedure. the same procedure was followed for a dataset of nasal brush bulk rna - seq samples from asthmatic donors pre - and postinhalation of corticosteroids ( n = 54 and 26, respectively ) and a dataset of airway biopsy bulk rna - seq samples from asthmatic donors and controls ( n = 95 and 38, respectively ). as these consisted of rna - seq data, no quantile normalization was applied. to map unseen scrna - seq and single-nucleus rna - seq data to the hlca, we used scarches, our transfer learning - based method that enables mapping of new data to an existing reference atlas. scarches trains an adaptor added to a reference embedding model, thereby enabling it to generate a common embedding of the new data and the reference, allowing reanalysis and de novo clustering of the joint data. the data to map were subsetted to the same 2, 000 hvgs that were used for hlca integration and embedding, and hvgs that were absent in the new data were set to 0 counts for all cells. raw counts were used as input for scarches, except for the ref. dataset, for which ambient rna removal was run previously on the raw counts. healthy lung data were split into two datasets: 3 ′ and 5 ′ based. lung cancer data were also split into two datasets: 10xv1 and 10xv2. the model that was learned previously for hlca integration using scanvi was used as the basis for the scarches mapping. scarches was then run to train adaptor weights that allowed for mapping of new data into the existing hlca embedding, using the following parameter settings: freeze - dropout: true; surgery _ epochs: 500; train base model: false; metrics to monitor: accuracy and elbo; weight - decay: 0; and frequency: 1. the following early - stopping criteria were used: early stopping metric: elbo; save best state metric: elbo; on: full dataset; patience: 10; threshold: 0. 001; reduce lr on plateau: true; lr patience: 8l and lr _ factor: 0. 1.