dataesr/scientific-paragraphs-categorization huggingface dataset:
C). In the case of S. japonicum, we wanted to avoid possible ZW hybrid assemblies that may be present in the published genome. We therefore extracted the BLAT best-hit of each protein-coding W-transcript from a male-derived transcriptome. The final list of protein coding W-candidates in the two species, as well as their respective homologs, is provided in Sup. Dataset 4. For the rest of the analysis, we focused on ZW homolog pairs (the 34 S. mansoni W-candidates with a Z-linked homolog, and the 48 S. japonicum W-candidates that mapped to Z-linked genes in S. mansoni, along with their homologs retrieved from the male transcriptome). Table  1. Number of candidate W-derived transcripts, and the genomic location of their closest S. mansoni homologs. "unique genes", in brackets, refers to the number of S.
Most W genes are found in younger evolutionary strata Panels A and B of Figure  1  show the location of Z-linked genes for which at least one homologous W-transcript was detected in S. mansoni and S. japonicum, along with the location of the ancestral (S0) and younger lineage-specific strata of the sex chromosomes (S1man for S. mansoni and S1jap for S. japonicum, updated from  Picard et al. 2018  with the latest S. mansoni assembly v7) (Sup. Dataset 5). Very few S0 genes have a W-homolog (5 in S. mansoni and 4 in S. japonicum, or 0. 8% and 0. 6% of the 635 annotated Z-specific genes identified in this stratum), as expected from an ancient degenerated non-recombining region. Three of these are found in both species, consistent with the stratum being ancestral, and much of the gene loss occurring before the split of the two lineages.
japonicum, we used published genomic data from individual miracidia (Le  Clec'h et al. 2018 ), which we sexed based on their ratio of Z:autosome genomic coverage, as well as on the number of reads that mapped perfectly to W-transcripts (Methods and Sup. Figure  4 ). Single nucleotide polymorphisms were then called on the resulting 11 males and 8 females, and mean F ST between males and females was inferred for each scaffold (Figure  1C  and Sup. Figure  5 ; scaffold F ST values are in Sup. Dataset 6). Most of the Z-chromosome to the distal end of S1jap showed consistently increased female-male F ST , confirming that this region corresponds to yet another young stratum of the ZW pair (now referred to as S2jap, a 28. 8Mb region that includes 720 genes). All W-transcripts that mapped to Z-linked scaffolds located in the S.
Patterns of divergence of old and young W-genes The amount of synonymous divergence (estimated as dS, the number of synonymous substitutions per synonymous site) between Z-and W-homologs is proportional to how long they have been non-recombining  (Kimura 1987; Lahn and Page 1999; Nicolas et al. 2005; Bergero et al. 2007; Nam and Ellegren 2008; White et al. 2015). Consistent with the putative strata inferred from the coverage and F ST analyses, S0 pairs have the highest dS in both species (median dS of 0. 877 and 0. 607 in S. mansoni and S. japonicum, respectively, Sup. Dataset 4). The median dS of the S. mansoni S1 stratum is lower than that of the S. japonicum S1 (0. 176 versus 0. 465), suggesting that at least parts of it may have stopped recombining more recently. Finally, S2jap ZW homologs have the lowest median dS (0.
085), in agreement with the most recent loss of recombination. W-linked genes typically show an increased ratio of non-synonymous relative to synonymous divergence (dN/dS) compared to other genomic regions, consistent with the excessive accumulation of deleterious mutations  (Bachtrog et al. 2008; Hough et al. 2014; Sigeman et al. 2019). To test for increased non-synonymous divergence on the W, we estimated dN and dS between W-genes and their Z-homologs in the outgroup species (W vs Z comparisons, e. g. S. mansoni W versus S. japonicum Z), as well as between the corresponding Z-genes and their Z-homologs in the outgroup species (Z vs Z) (Figure  2  and Sup. Dataset 10). As expected under degeneration of the W-chromosome, dN/dS values for W vs Z comparisons are higher than for Z vs Z comparisons (p<0.
Datasets 11 and 12). Reads were mapped to curated transcriptomes that included our W-candidates (see Methods) using Kallisto, an RNA quantification program capable of inferring paralog/allele-specific expression  (Bray et al. 2016 ). An overview of gene expression of all protein-coding W-candidates is provided in Sup. Figures  6  and 7 , and shows that the majority of them are expressed in at least some female stages (but not or much less expressed in males, confirming that we are for the most part correctly discriminating between Z-and W-derived expression of ZW gene pairs). Figure  3  shows the distribution of female expression levels of W-candidates from the different strata and those of their Z-homologs (when more than one W-candidate mapped to the same Z-linked gene, only the longest was kept; see Sup.
Finally, although direct comparisons of the gene expression of Wcandidates (or Z-homologs) between strata are only significant for some developmental stages (Kruskal-Wallis test, Sup. Tables  4 to 6 ), S0 W-linked genes and their Z-linked homologs have the highest median expression level at all time points available for both species (Figure  3 ), providing further support for their functional importance (and/or potentially contributing to the differences in dN/dS observed between strata). mansoni, and blue for S. japonicum. An additional dataset with S. mansoni mature adults is plotted in Sup. Figure  8. Panel B shows gene expression values (TPM) for the S. mansoni Wcandidates and their Z-homologs according to their respective strata (S0 in grey, S1 in orange) across five developmental stages: cercariae "Cerc", three subsequent schistosomulum stages "Som1-3" and immature adult schistosomes "Im".
Dataset 4), a Ubiquitin conjugating enzyme variant (Uev, OrthoGroup OG0000869) and an Ankyrin repeat and KH domain-containing protein 1 (ANKHD1, OrthoGroup OG0000874). Of the three, U2AF2 stands out as fitting all three predictions (Figure  4 ), as it has high expression throughout female development and dN/dS below 0. 1 in both species. It is also the only W-candidate in either species with the term "female sex differentiation" in its functional annotation (Sup. Datasets 13 and 14), further strengthening the case for its role in determining sex. The S. mansoni W-copy of ANKHD1 is much shorter than the Z-copy, or than the S. japonicum Z-and W-homologs, and it has a higher branch-specific dN/dS than any of its homologs, consistent with loss of function. It also shows no expression at any female stage of S.
japonicum ZW pair that could not be detected with coverage approaches  (Picard et al. 2018) , demonstrating the power of this method for studying sex-specific sequences in species that have varying levels of sex chromosome differentiation, or for which such information is missing. Finally, our pipeline is based on the published and efficient k-mer manipulation package BBMAP  (Bushnell 2014) , making it easy to implement for any organism for which male and female data is available, even in the absence of a reference genome.
Data All analyses were performed on publicly available data. The S. mansoni genomic libraries were downloaded from Bioproject PRJEB2320 (Wellcome Sanger Institute), and the Table  1. number of perfectly matching male and female reads (reads with 0 edit distance "NM:i:0") to each transcript were counted. All transcripts that had fewer than 20 perfectly matching female reads and/or a ratio of (male:(male+female)) perfect matches of more than 0. 1 were removed. In order to have a more comprehensive set of W-transcripts for downstream analyses, the coding sequences of the 32 annotated W genes were added to our set of candidates. In order to collapse transcripts that were both in the k-mer and annotated sets, we then used a perl script (SpliceFinder. pl) to produce clusters of transcripts with >100 bp of alignment and less than 1% divergence (putative isoforms), and kept only the longest isoform per cluster.
We therefore mapped our candidates to a long k-mer female transcriptome assembly (SOAPdenovo-trans assembly of all reads in Bioproject PRJNA343582, with K=65, Sup. Dataset 15), which should be largely devoid of ZW hybrid assemblies. Wcandidates were mapped to the transcriptome with BLAT, and scaffolds with a minimum match score of 50 and less than 1% divergence were retrieved. Cap3  (Huang and Madan, 1999)  was used to further assemble them. We merged the output of Cap3 with our 157 transcripts and used Splicefinder. pl to keep the longest transcript per gene. We once again mapped the four male-only samples and the three mixed samples to the resulting set and followed the same filtering approach described above, yielding a final set of 96 W-specific candidates. To identify the Z-homologs for the S.
japonicum W-candidates, we assembled a male transcriptome from male reads (SRR8175618, Sup. Dataset 15). The reads were trimmed with the Trimmomatic package  (Bolger et al. 2014 ) and then assembled using Trinity  (Grabherr et al. 2011)  followed by Cap3  (Huang and Madan 1999). We mapped our candidates to the male assembly using BLAT (with a translated query and database and a minimum match score of 50), and selected only the transcript with the highest match score for each W-candidate, which was used as its homolog. The completeness of both the female and male transcriptomes was assessed using  BUSCO (Felipe et al. 2015)  in the transcriptome mode with the metazoa-specific set (metazoa_odb10) and compared with the BUSCO scores for the published S. japonicum and S. mansoni transcriptomes (Sup.
Mapping of W-candidates to S. mansoni coding sequences We mapped the filtered sets of candidates of both species to the published S. mansoni coding sequences (https://parasite. wormbase. org/index. html, [Howe et al. 2016; Howe et al. 2017] ) using BLAT with a translated query and dataset, and a minimum match score of 100 (Table  1 ). Only the CDS with the highest matching score was kept for each candidate. In the case of S. mansoni, we performed three different mappings: 1. the filtered original candidates against the full set of S. mansoni CDS; 2. the final combined set against the full S. mansoni CDS; 3. the final combined set against the S. mansoni CDS, but with all the different transcript isoforms of the 32 annotated W genes removed using a perl script, in order to detect close homologs of W-linked genes in the genome (Table  1 ).
Definition of shared and lineage-specific strata based on coverage analysis De novo determination of Z-specific regions in Schistosoma mansoni Z-specific regions were determined for the latest version of the S. mansoni genome based on female and male genomic coverage, following the bioinformatic pipeline described in  Picard et al. 2018. The reference genome, coding sequences (CDS) and their respective chromosomal locations (BioProject PRJEA36577, version WBPS14) were obtained from the WormBase Parasite database (https://parasite. wormbase. org/index. html, [Howe et al. 2016; Howe et al. 2017] ), on the 30 th of October 2020. We estimated the genomic coverage for females (ERR562990) and males (ERR562989) by mapping the DNA reads to the genome with  Bowtie2 (v2. 3. 4. 1)  and by using the uniquely mapped reads as SOAPcoverage input (SOAPcoverage v2.
7. 7). The coverage analysis was performed for windows of 10kb. We classified as pseudoautosomal (PAR) any window on the ZW linkage group that had a F:M coverage ratio higher than the 2. 5 percentile of the autosomes. The remaining windows were considered to be putatively Z-specific. The 1% of Z-specific windows with the highest F:M coverage ratio were further marked as "ambiguous" and not considered for strata assignments (Sup. Figure  14 ). The classification of Z-specific and PAR regions, and of the CDS that they contain, is reported in Sup. Dataset 5. Inference of the location of S. japonicum scaffolds along the S. mansoni Zchromosome S. japonicum reference genome were obtained from the WormBase Parasite database (https://parasite. wormbase. org/index. html, [Howe et al. 2016; Howe et al.
2017] ), on the 30 th of October 2020 (BioProject PRJEA34885, version WBPS14). We mapped S. mansoni CDS to S. japonicum scaffolds using BLAT  (Kent 2002 ) with a translated query and database. The BLAT alignment was then filtered to keep only the mapping hit with the highest score for each S. mansoni CDS. In a second filtering step, when several S. mansoni genes overlapped on the S. japonicum genome by more than 20 bp, we kept only the highest mapping score. The position of each S. japonicum scaffold on the S. mansoni Z-chromosome was inferred from the position of the S. mansoni genes that mapped to it. japonicum (see above). Genes were assigned to the stratum S1man if they were located in a Z-specific window in S. mansoni but their CDS mapped to a scaffold classified as PAR in S.
Strata definition japonicum, and vice versa for S1jap. Genes that mapped to Z-specific genomic regions in both species were assigned to the stratum S0. Finally, the analysis of F ST between males and females (see below) revealed a new stratum specific to the S. japonicum lineage (S2jap). Genes were assigned to this stratum if they mapped to windows/scaffolds classified as PAR in both species, but the mean F ST value of the S. japonicum scaffold was above the 90th percentile of the distribution of the entire genome. Final coordinates of the strata were defined by the first base of the first S. mansoni CDS assigned to a specific stratum and the last base before the start of the first gene assigned to a different stratum (Sup. Dataset 5, Sup. Table  7 ). More than five consecutive assignments to a given region were needed to change strata.
If in those five first CDS one was assigned as "ambiguous", the original assignment of the windows was considered. The coding sequences of W-candidates of both species (and of their closest homologs in S. japonicum) were obtained with the command-line version of Genewise (Wise2 package v2. 4. 1), using the protein sequence of the closest S. mansoni homologs (section 4. 2) as input. The coding sequences of W-candidates and their closest homologs (within the same species) were aligned with the TranslatorX package (Abascal et al. 2010) with the "gblocks" option to filter out unreliable sections of the alignment. The dN and dS values were obtained with KaKs_calculator2. 0  (Wang et al. 2010 ) using the Yang Nielsen algorithm (YN). For the dN/dS and dS between ZW pairs of S. mansoni and S. japonicum (Figure  2A ), we only considered the KaKs_calculator2.
0's estimates for pairs with 300 sites or more, and dS above 0 (Sup. Dataset 4). To estimate dN and dS between W-genes and their Z-homologs in the outgroup species (W vs Z comparisons), as well as between the corresponding Z-genes and their Zhomologs in the outgroup species (Z vs Z), we considered only the instances in which the ZW pair and at least one sequence from the outgroup species clustered in the same Orthogroup (section 4. 7). When multiple orthologs were present in the outgroup species, the sequence with the highest BLAT match score to the W-candidate was used. Sequence alignments (of the three sequences) and pairwise dN and dS estimation were then performed as before (Sup. Dataset 10). To obtain branch-specific estimates of dN/dS for W-candidates shared between the two schistosome lineages (Fig.
4 ), we aligned W-and Z-homologs from both species, as well the closest Clonorchis sinensis sequence (an outgroup of schistosomes) placed in the respective Orthogroup (section 4. 7). Trees were constructed with the maximum likelihood method  (Felsenstein, 1973)  implemented in the PhyML package with default parameters  (Guindon and Gascuel, 2003)  and 100 bootstraps, and visualized on the IToL web server  (Letunic and Bork, 2016). Branch-specific divergence rates were estimated with PAML 4. 9  (Yang, 2007) , and compared to a null model presuming the same dN/dS on all branches (likelihood-ratio test,  Jeffares et al. , 2015).
Transcriptome curation and gene expression analysis Curation To avoid multi-mapping reads resulting from having multiple transcript isoforms of the same gene in the expression analysis, we used the in-house script (Splicefinder. pl) to remove all the isoforms from the published transcriptomes of both species. In addition to that, we mapped our set of W-candidates and their homologs to their respective transcriptomes and removed any transcripts with matches > 100 bp and less than 5% divergence. This is important to remove all the existing isoforms of our transcripts from the published transcriptomes, some of which are possibly hybrid assemblies between the Z and the W. Following that, we added our candidate set to the transcriptomes in order to perform gene expression analysis to untangle the differences in expression patterns between males and females.
Expression analysis For S. japonicum, the analysis of expression was carried out using 48 S. japonicum RNA-seq read libraries corresponding to three replicates of RNA-seq read data collected at 8 time points of male and female S. japonicum development in the definitive host  (Wang et al. 2017, bioproject PRJNA343582). For S. mansoni, the expression analysis was carried out using 28 S. mansoni RNA-seq libraries corresponding to two replicates of RNA-seq read data from two different studies (20 libraries from PRJNA312093  (Picard et al. 2016 ) and 8 libraries from PRJEB1237) for different developmental stages: cercariae, three schistosomula stages, immature (unpaired) and mature (paired) adults. The transcriptomes curated specifically for the expression analysis are provided as a Sup. Dataset 16.
Identifying the shared candidates using OrthoFinder The identification of the orthologous genes between the two species was performed using OrthoFinder  (Emms et al. 2019). We followed the same steps detailed in section 4. 6 to curate the transcriptomes of the two species; however, we only included coding sequences of W-candidates and their Z-homologs in S. japonicum obtained in section 4. 5 (the two curation pipelines are outlined in Sup. Figure  15 ). We downloaded the coding sequences of Clonorchis sinensis from the WormBase Parasite database and used it as an outgroup. As OrthoFinder takes only protein sequences as input, we used an in-house perl script ''GetLongestAA_v1_July2020. pl'' to perform 6-frame translation of all the transcripts and retain only the longest isoforms. Orthofinder was then run using the three sets of protein sequences to assign proteins to clusters of homologs ("orthogroups").
japonicum genomic libraries from the three following BioProjects: PRJNA432803 (IST Austria), PRJNA354903 (Wuhan University), PRJNA650045 (University of Texas at Arlington). The RNA-seq libraries for S. mansoni were downloaded from Bioprojects PRJNA312093 (Université of Perpignan Via Domitia) and PRJEB1237 (Wellcome Sanger Institute), and the S. japonicum RNA-seq libraries from PRJNA343582 (National Institute of Parasitic Diseases), PRJNA252904 (Chinese Academy of Medical Sciences and Peking Union Medical College), and PRJNA504625 (Wuhan University). A detailed list of individual accession numbers, and of the steps for which they were used, is provided as Sup.
The coverage-based assignment of S. japonicum scaffolds to Zspecific (Z) or pseudoautosomal (PAR) regions was obtained from Picard et al. 2018, and is reported in Sup. Dataset 5. The de novo strata assignment shown in Figure 1 was based on the comparison of the classification of the genomic location of each S. mansoni gene as Zspecific or PAR, and the classification of the scaffold that their CDS mapped to in S.
Code availability: All supplementary codes are available in supplementary materials (Sup. Codes 1 to 14), as well as on: https://github. com/Melkrewi/Schisto_project. Supplementary datasets are available at: https://seafile. ist. ac. at/d/2d9ce33a4e0c45aeadd1/. Data availability: All analyses were performed on previously published and publicly available data: accession numbers are provided as Sup. Table  1.
S. japonicum genomic libraries from the three following BioProjects: PRJNA432803 (IST Austria), PRJNA354903 (Wuhan University), PRJNA650045 (University of Texas at Arlington). The RNA-seq libraries for S. mansoni were downloaded from Bioprojects PRJNA312093 (Université of Perpignan Via Domitia) and PRJEB1237 (Wellcome Sanger Institute), and the S. japonicum RNA-seq libraries from PRJNA343582 (National Institute of Parasitic Diseases), PRJNA252904 (Chinese Academy of Medical Sciences and Peking Union Medical College), and PRJNA504625 (Wuhan University). A detailed list of individual accession numbers, and of the steps for which they were used, is provided as Sup.
Results Gathering traits, occurrences and IUCN status of vertebrates. We combined functional trait information, spatial occurrences, and IUCN status of more than 50,000 species of terrestrial mammals, birds, amphibians, reptiles, and freshwater fishes, representing 67% of the vertebrate fauna (Supplementary Table  1 , Supplementary Data 1, Supplementary Fig. 1 ) to conduct a realmscale analysis of current patterns of functional diversity and its erosion due to the potential loss of threatened species. We estimated the functional diversity of each realm using a probabilistic approach, providing more realistic functional spaces than other methods, such as convex-hulls  18, 19. We collected information on traits related to ecological functions (hereafter called functional traits) for the five vertebrate groups using the most recent functional trait databases  9, [20] [21] [22].
In addition, we retrieved the most comprehensive available species lists compiled at the realm scale  [23] [24] [25]. Because the functional trait databases for none of the groups were complete, a specific imputation procedure was used to complement this missing information (see 'Methods' and Supplementary Table  2 ). Using phylogenetic information, we imputed the values of the missing functional traits and estimated the position of the imputed species in the functional space (Supplementary Table  2 ). Matching species occurrences across the six biogeographic realms and functional traits showed that 67% of the species with geographic distribution information are functionally described (Supplementary Table  1 ). No substantial distortion toward some specific realm was identified except for reptiles in Indo-Malay where a lower proportion of species has been functionally described compared to the other realms (χ 2 = 129.
Methods Spatial database. We collected species occurrences from the most accurate and available source of data for each taxonomic group. For mammals, birds, reptiles and amphibians, we used the IUCN spatial database to assign realm identity for each species  15. By doing this, we assigned a realm for 5489 mammal species, 10,787 bird species, 5489 reptile species and 5833 amphibian species. Since IUCN spatial database does not cover all species, we completed our database with two additional sources of species occurrences: (1) the WWF WildFinder species database  23  , except for mammals where we used the latest version of the species distribution provided by ref. 24. If (1) was not available, we used (2) the global biodiversity information facility (GBIF). Using WWF WildFinder, we assigned a realm for 1634 bird species, 7378 reptile species and 2006 amphibian species.