Significance From both evolutionary and biomedical perspectives, ectopic organ development is a promising paradigm to investigate the emergence and integration of novel complex structures outside their normal biological context. However, the best known examples of ectopic organ induction require genetic techniques only available for a few model systems. Here, we report the ectopic induction of complex and functional organs, compound eyes, by down-regulation of a single transcription factor through RNAi, a technique known to work well across a broad taxonomic range. These results provide a remarkable example of the ability of developmental systems to channel massive perturbations toward orderly and functional outcomes and open the use of ectopic eyes as an accessible paradigm of ectopic organ development.

Abstract Complex traits like limbs, brains, or eyes form through coordinated integration of diverse cell fates across developmental space and time, yet understanding how complexity and integration emerge from uniform, undifferentiated precursor tissues remains limited. Here, we use ectopic eye formation as a paradigm to investigate the emergence and integration of novel complex structures following massive ontogenetic perturbation. We show that down-regulation via RNAi of a single head patterning gene—orthodenticle—induces ectopic structures externally resembling compound eyes at the middorsal adult head of both basal and derived scarabaeid beetle species (Onthophagini and Oniticellini). Scanning electron microscopy documents ommatidial organization of these induced structures, while immunohistochemistry reveals the presence of rudimentary ommatidial lenses, crystalline cones, and associated neural-like tissue within them. Further, RNA-sequencing experiments show that after orthodenticle down-regulation, the transcriptional signature of the middorsal head—the location of ectopic eye induction—converges onto that of regular compound eyes, including up-regulation of several retina-specific genes. Finally, a light-aversion behavioral assay to assess functionality reveals that ectopic compound eyes can rescue the ability to respond to visual stimuli when wild-type eyes are surgically removed. Combined, our results show that knockdown of a single gene is sufficient for the middorsal head to acquire the competence to ectopically generate a functional compound eye-like structure. These findings highlight the buffering capacity of developmental systems, allowing massive genetic perturbations to be channeled toward orderly and functional developmental outcomes, and render ectopic eye formation a widely accessible paradigm to study the evolution of complex systems.

Developmental systems channel tissues with broad potential into tightly regulated, specific fates, thereby enabling the formation of highly complex traits like limbs, brains, photic organs, or eyes. How complex traits develop from undifferentiated precursor tissues and how this ability itself originated and diversified are questions that have motivated biologists since the emergence of evolutionary thinking. The evolution and development of arthropod compound eyes in particular has attracted significant attention due to the high level of structural and regulatory complexity required to produce a functional organ: Functional compound eyes exhibit ommatidial organization, possess neural projections connecting to the central nervous system, express eye development and photoreceptor genes, and enable an integrated behavioral response to light stimuli. Insect eyes develop from pluripotent anterior head regions also capable of generating single-lens ocelli and nonvisual epidermis. Patterning of this region, best understood in Drosophila flies and Tribolium beetles, depends on a complex and only partly conserved network of interacting genes (1, 2). Some of these genes, like Pax6/eyeless, can act as “eye master genes” when overexpressed outside their normal expression range and induce ectopic eye-like structures in Drosophila flies (3) and Xenopus frogs (4). Ectopic development of complex structures including eyes has emerged as a useful paradigm for investigating the initiation and integration of complex traits following ontogenetic perturbation (3, 5, 6). However, while ectopic eyes in flies form ommatidia including photoreceptors and accessory cells capable of transducing light stimuli that extend axonal projections to the central nervous system, they fail to connect to the optic lobe (7) and never achieve full neural integration and corresponding behavioral functionality. Further, use of this paradigm in the broader phylogenetic context needed for evolutionary inference is hindered by the relative scarcity of species in which targeted overexpression techniques are available.

Ectopic structures externally resembling compound eyes are also inducible in two species of scarabaeid beetles—Onthophagus taurus and Onthophagus sagittarius (8). Rather than being brought about through targeted overexpression of master regulator genes, this induction results from the knockdown of the transcription factor orthodenticle (otd) (8). This phenotype is surprising: otd function has been studied in detail in Tribolium beetles, where it is needed for photoreceptor development in bilateral compound eyes but plays no detectable role in specifying the external morphology of eyes or the head in general (8, 9), and in Drosophila, where it is required for proper rhabdomere and photoreceptor development in compound eyes (10) and for the formation of medial ocelli (11) (i.e., single-lens eyes that differ from compound eyes in many fundamental aspects). However, all extant scarabaeids and almost all other beetles, including Tribolium, lack medial ocelli (12), and even though dorsalization of compound eye compartments has evolved in a subset of insect taxa (the turbinate eyes of some male mayflies being an extreme example), completely distinct compound eyes developing middorsally on the cephalic vertex are not known from any extant insect lineages (13). Here we report on the morphological and transcriptional similarities between regular compound eyes and otd1RNAi-induced ectopic compound eyes in scarabaeid beetles and assess their functionality in a light-aversion behavior assay. We use our results to discuss the role of developmental systems in facilitating complex, functional, as well as novel developmental outcomes in the face of massive ontogenetic perturbations.

Results and Discussion Orthodenticle Down-Regulation Induces Ectopic Structures Externally Resembling Compound Eyes in Onthophagini and Oniticellini. We first assessed whether the induction of ectopic compound eyes via down-regulation of orthodenticle may be restricted to the closely related Onthophagus species O. taurus and O. sagittarius or alternatively constitute a more taxonomically widespread phenomenon. To do so, we cloned orthodenticle orthologs in three additional scarabaeid species (Onthophagus binodis and Digitonthophagus gazella, tribe Onthophagini; and Liatongus militaris, tribe Oniticellini; Fig. 1A and Dataset S1), followed by larval otd1RNAi in all species. otd1RNAi reduced the size of the metasternal plate and pronotal ornaments, caused head midline defects, eliminated or greatly reduced horns and ornaments located along the posterodorsal head, and induced small ectopic horns in the same area in both tribes (Fig. 1B and Figs. S1–S6). Furthermore, in all species, we observed formation of ectopic compound eyes at the posterodorsal head (8/20 in O. binodis; 52/74 in D. gazella; 7/92 in L. militaris), which first became evident by the midpupal stage as paired pigmented spots flanking the posterodorsal head midline (Fig. 1C). We replicated these results in O. sagittarius (51/139) and O. taurus (where ectopic compound eyes only develop when both Ot-otd1 and Ot-otd2 are knocked down: 5/48). Our data thus show that the ability to develop ectopic compound eyes through larval otd1 down-regulation is not idiosyncratic to the genus Onthophagus. Fig. 1. Beetle orthodenticle orthologs and phenotypes observed after otd1RNAi. (A) Gene tree showing relationships between orthodenticle/OTX class genes from scarabaeid beetle species and the red flour beetle Tribolium castaneum. The * indicates partial gene sequences retrieved from genomic DNA. (B) Table showing distribution of RNAi phenotypes corresponding to the gene indicated in the left row. Each gene was knocked down in the species from which it was cloned; the dendrogram indicates inferred phylogenetic relationships among species. A tick mark indicates the presence of an unambiguous RNAi phenotype; a cross indicates a wild-type–like phenotype. DHM, dorsal head midline defect; EELS, ectopic eye-like structure; EHH, ectopic head horns; VMD, ventral midline defect. (C) Dorsal view of heads at midpupal stage from control (Left) and otd1 (Right) dsRNA-injected individuals from all five species. Blue half-arrowheads point at lateral compound eyes; red half-arrowheads indicate ectopic eyes. (Scale bar, 0.5 mm.) (D) External morphology of ectopic eyes in adults ranges from large, convex structures with evident ommatidial arrangement (Top) to small, inconspicuous pits (Bottom). Right shows a higher magnification view of the boxed areas in Left. Labeling as in C. Fig. S1. Ventral midline defect (VMD) phenotype. otd1RNAi causes a substantial reduction of the metasternal plate (black arrowheads) in pupae (shown here, Right) and adults of all species compared with controls (Left). Fig. S2. Thoracic dorsal ornaments (white arrowheads) are reduced after otd1RNAi (Right) relative to controls (Left) in males and females of L. militaris (Top), females of D. gazella (Middle), and males and females of O. binodis (Bottom). Fig. S3. Posterior head phenotypes (white arrowheads) induced after otd1RNAi (Right) compared with controls (Left). In L. militaris males (Top), the posterior medial protuberance is reduced in size; in D. gazella males (Top Middle), the posterior lateral head horns are reduced in size and located closer to the head midline, while in females (Bottom Middle), the posterior head ridge is indented around the midline; in both sexes of O. binodis (Bottom), the posterior head ridge is indented around the midline. Fig. S4. Dorsal head midline defect (DHM, white arrowheads) induced after otd1RNAi (Right) compared with controls (Left). In both sexes in L. militaris (Top), the area comprised between the two ridges on the head is reduced; in D. gazella (Bottom), the area with inconspicuous punctuation comprised between the medial head ridge and the horns (in males) or between the medial ridge and the posterior ridge (in females) becomes narrower. Fig. S5. Ectopic head horn phenotype (EHH, white arrowheads) induced after otd1RNAi (Right) compared with controls (Left). Small ectopic horns for both sexes in L. militaris (two Top), O. taurus (two Middle), and O. sagittarius (only male shown, Bottom). Notice reduction of other head horn structures in otd1RNAi males relative to control individuals. (Scale bars: 1 mm.) Fig. S6. Phylogenetic distribution of otdRNAi -induced phenotypes in beetles. The dendrogram on top depicts the phylogenetic relationships among studied species. Red flour beetle T. castaneum otd1RNAi phenotype is described in ref. 8. SEM Imaging and Immunohistochemistry Reveal Striking Parallels Between Ectopic Compound Eyes and Wild-Type Eye Morphology. We used scanning electron microscopy to image adult ectopic compound eyes and assess their external morphology. In all species, we observed putative ommatidial lenses organized in hexagonal arrays reminiscent of those found in regular lateral compound eyes. Even though ectopic compound eyes varied widely in their external expression within and between species (the largest and most complex being found in O. sagittarius), ommatidia-like structures were evident in each case (Fig. 1D). Using cryosectioning and immunohistochemical staining, we found that compound eye-like external features of ectopic compound eyes were underlain by corresponding internal features, specifically crystalline cones surrounded by putative photoreceptor and accessory cells, albeit arrayed more irregularly (Fig. 2 A–D). Strikingly, some of the sections showed organized neural-like tissue extending from ectopic eyes onto a deeper flask-shaped structure of nonmuscular identity (Fig. 2E). Taken together, analysis of external and internal morphology supports that ectopic compound eyes share structurally defining traits with regular compound eyes, despite being smaller in size and more irregular in organization. Fig. 2. Histological structure of regular scarabaeid beetle compound eyes compared with ectopic eyes. (A) Transverse section through a D. gazella late pupal head showing the internal structure of the compound eyes (blue half-arrowheads) and optic lobes. (B) Transverse section through an otd1RNAi D. gazella late pupal head, showing sunken ectopic eyes in cross-section (red half-arrowheads). (C and D) Structure of the distal part of a regular compound eye (C) and ectopic eyes (D) from an otd1RNAi O. sagittarius, showing similar composition and arrangement of optical elements. (E) Detail of a transverse section through an otd1RNAi D. gazella late pupal head showing the distal part of paired ectopic eyes and underlying optic nerve-like structures. Abbreviations: cc, crystalline cone; cn, cone cell nuclei; co, corneal lens; cz, clear zone; la, lamina; lo, lobula; lp, lobula plate; me, medulla; ph, photoreceptor cells. Nucleic acids and cuticle are shown as cyan in A, B, and E and blue in C and D; acetylated tubulin is shown as orange in A, B, and E and green in C and D; serotonin plus nonspecific staining is shown as green in A; F-actin, birefringent crystalline cones and lenses, and autofluorescent fat granules are shown as red in B–D. The Transcriptional Signature of the Middorsal Head Converges onto That of Regular Compound Eyes Following Orthodenticle Down-Regulation. Although ectopic compound eyes thus appear morphologically similar to compound eyes, their ability to also function alike would critically depend upon the coordinated ectopic expression of the retinal and photoreceptor gene networks. Thus, we tested whether ectopic compound eyes are transcriptionally closer to regular compound eyes than to the posteromedial head of control animals. Using RNA-sequencing (RNA-seq), we characterized and contrasted the transcriptional repertoire of the posteromedial head (PMH) and wild-type compound eye (EYE) tissues of both control and Dg-otd1RNAi 4-d-old pupae of D. gazella (Fig. 3A). We chose D. gazella due to higher penetrance of the ectopic eye phenotype; furthermore, since ectopic compound eyes in this species appear smaller and simpler than in O. sagittarius, we considered it a conservative choice. Our results showed that the transcriptional profile of EYE tissue for both treatments differs strongly from that of the control PMH tissue. Indeed, three out of four replicates of the Dg-otd1RNAi PMH samples (all of which developed ectopic eyes) clustered more closely with the EYE samples than with control PMH samples (Fig. 3B). Furthermore, a Gene Ontology analysis showed significant enrichment for visual, photoreception, signal transduction, and rhabdomere categories of differentially expressed genes in otd1-PMH samples relative to ctrl-PMH samples (Datasets S2–S11). Most of these genes, including orthologs of ninac, arrestin, chaoptin, and slowpoke-binding protein, were also differentially up-regulated in ctrl-EYE relative to ctrl-PMH samples (Fig. 3C, Left). Collectively, these data show that ectopic compound eyes exhibit a transcriptional profile similar to that of wild-type compound eyes. Fig. 3. Transcriptional profiling of control and otd1RNAi head regions via RNA-seq. (A) Dorsal view of midstage pupal heads showing tissue regions dissected as postero-medial head epidermis (pmh, red) and compound eye (eye, blue). (B) Sample correlation heatmap (middle) and sample clustering tree (margins) generated from log2-transformed standardized expression matrix of 4,521 differentially expressed transcripts. Each sample is color-coded to show the Experimental Tissue × Treatment Group to which it belongs. (C) Plots for selected individual genes showing counts (y axis, log scaled) for each replicate, grouped by Tissue × Treatment. Left shows four genes associated with retinal development in flies (NINAC, arrestin, chaoptin, and slowpoke-binding protein); Top Right shows orthodenticle-1 levels; Bottom Right shows higher counts of the photoreceptor-controlling factor pph13; two Middle Right show up-regulation of two main members of the retinal network, wingless and hedgehog, after otd1 knockdown. P values correspond to results of Wald tests comparing ctrl-PMH to otd1-PMH, except for otd-1, which was not significant for that contrast; the P value (†) shown instead corresponds to the ctrl-EYE to otd1-EYE contrast, providing additional confirmation of the effectiveness of otd1 transcript down-regulation in our experiments. Ectopic Compound Eyes Partially Rescue Visual Function in Blinded Beetles. Combined, our data reveal significant morphological, cellular, neuroanatomical, and transcriptional congruence between ectopic compound eyes induced after otd1 knockdown and wild-type lateral compound eyes. To test whether ectopic compound eyes are sufficiently complex to support functional integration with the rest of the organism, we assessed whether they could rescue visually cued behavioral responses in individuals deprived of regular compound eyes. We designed a behavioral assay where an individual beetle is placed inside a dish in a dark room and allowed to walk; a cold, bright, flickering light is then shone in front of the beetle. Wild-type individuals (B−I−) react without exception by stopping, lowering their heads, turning around, and quickly moving away from the light source (11/11). By ablating wild-type larval head tissue fated to form compound eyes (14), we generated eyeless beetles (B+I−) that invariably failed to show any reaction to light (0/15). We then repeated the ablation in otd1RNAi individuals. We found that most individuals possessing ectopic compound eyes but lacking regular lateral compound eyes (B+I+) eventually reacted to the light stimulus by either lowering their head or turning around or a combination thereof (11/12) (Table S1 and Movie S1). These results indicate that, despite the impact of the eye ablation treatment on overall vigor, ectopic compound eyes can at least partially rescue the behavioral response to light in an otherwise eyeless beetle (P < 0.01) and are thus functionally integrated with the central nervous system of the insect. Table S1. Individual results from behavioral tests for ectopic eye functionality Ectopic Eye Formation Provides a Useful and Widely Accessible Paradigm to Study the Ontogeny and Evolution of Complex Systems. Targeted overexpression of eyeless/Pax6 is known to induce development of ectopic eye-like structures in fruit flies and frogs, but evidence of full functional integration of ectopic eyes is lacking. In contrast, our results show that in scarabaeid beetles, RNAi-induced depletion of orthodenticle/OTX homologs results in development of functional ectopic compound eyes. As such our results document the formation of a highly complex and functional organ in a novel location following the down-regulation of a single gene, thereby highlighting the flexibility and modularity of developmental systems to generate complex, well-integrated structures even when confronted with major regulatory perturbations and outside their conventional anatomical context. The regulatory mechanisms leading to ectopic compound eye development in beetles remain to be fully investigated, but comparing our RNA-seq dataset to corresponding information on the fly retinal gene network, we find that while the sign of some interactions is conserved, others have reversed. For example, in both Drosophila and Onthophagus, loss of orthodenticle results in increased wingless expression (Fig. 3C). In contrast, loss of otd expression leads to the loss of hedgehog expression in flies (15) yet to its up-regulation in otd1RNAi beetles (Fig. 3C). Since hedgehog is required to induce neurogenesis and synapse formation between brain and photoreceptor neurites (16), we speculate that differences between the fly and beetle retinal networks might explain why fly ectopic eyes do not reach functional integration. A further difference between flies and beetles is that the latter lack ocelli, except for a subset of species in 8 out of ∼200 beetle families currently recognized (12). Ocelli are optical sensory structures simpler than compound eyes yet controlled, at least as far as is known in flies, by the same developmental gene network (17). Since ocelli are believed to be part of the basal insect ground plan and thus assumed to have been lost in beetles (12), it is conceivable that ectopic eye development seen after otd1RNAi in this group is mediated by activation of a vestigial and incomplete ocellar-fate program that eventually defaults into a compound eye fate. However, how a vestigial and incomplete developmental program can ultimately yield a complete and functional developmental product as complex as a compound eye remains entirely unclear. A wider taxonomic sampling is clearly needed to determine whether lack of ocelli correlates with the propensity to form dorsal ectopic eyes and which retinal network (beetle or fly) more closely reflects the ancestral arthropod arrangement; fortunately, while targeted gene overexpression techniques are currently limited to a few model systems, RNAi-mediated gene down-regulation works remarkably well in a wide variety of arthropods. Thus, our work opens the possibility of exploring the taxonomic breadth and conservation of ectopic compound eye development induced by orthodenticle knockdown. More generally, our results show that down-regulation of transcription factors that govern the development of entire body regions does not have to result solely in the morphological disruption of their corresponding domains but may also provide opportunities for developmental systems to settle into alternate stable states including, in at least this case, the formation of a complex and functionally integrated trait in a novel location. Our findings thus provide a remarkable example of the buffering capacity of developmental systems, allowing massive genetic perturbations to be channeled toward orderly and functional developmental outcomes. Further, developmental buffering and guiding toward functional integration as seen here may constitute key factors in promoting both evolutionary as well as technological innovation: On one hand, these developmental features are likely key facilitators of heterotopy, a widespread yet understudied phenomenon whereby the development of an organ or tissue is shifted to a new spatial location (18). On the other hand, the modular, reciprocally self-constructing nature of developmental processes is instrumental to the biomedical goal of growing ex situ organoids for research and transplantation (19). Whether used in basic or applied research, our findings render ectopic eye formation a widely accessible paradigm to study the mechanistic basis of the developmental flexibility that enables the evolution and reconstruction of complex systems.

Materials and Methods Beetle Husbandry. Beetles were obtained from cow pastures around Bloomington, Indiana; Chapel Hill, North Carolina; and Busselton, Australia (O. taurus); Imbil, Australia (O. sagittarius); Kualoa, Hawaii (O. sagittarius, D. gazella, L. militaris); and Waimea, Hawaii (O. binodis). Experimental animals were generated and maintained as described elsewhere (8, 20) either at 24 °C (O. taurus, O. binodis) or at 28 °C (O. sagittarius, D. gazella, L. militaris). Orthodenticle Cloning, Sequencing, and Phylogenetic Analysis. Ot-otd1, Ot-otd2, Os-otd1, and Os-otd2 sequences were retrieved and cloned as previously described from genomic and transcriptomic databases (8, 21, 22). A fragment of Ob-otd1 was partially cloned using degenerate PCR from cDNA; a fragment of Ob-otd2 was amplified and sequenced from genomic DNA using cross-specific primers. Dg-otd1, Dg-otd2, and Lm-otd1 sequences were retrieved from transcriptomes assembled de novo from RNA-seq data (Transcriptome Assembly and Annotation). Multiple sequence alignment (MSA) and phylogenetic analyses were made using Geneious 8.1 (23); the MSA was generated using the “Translation align” tool and the MAFFT method (24), and a gene tree was inferred using RAxML 7.2.8 (25) with the GTR-GAMMA model and default settings. otd1 RNAi. Targeted gene knockdown was achieved by injection of double-stranded RNA derived from a fragment of each target gene, as detailed previously (8, 26). Template DNA containing ∼500-bp orthologous fragments of otd was amplified by PCR from either cloned plasmids (Ot-otd1, Ot-otd2, Os-otd1, Ob-otd1, Dg-otd1) or from cDNA using species-specific primers flanked by T3 and T7 binding sequences (Lm-otd1). The templates were transcribed in vitro using T3 and T7 RNA-polymerases to generate forward and reverse RNA strands using MEGAscript T7 and T3 Kits (Life Technologies). After DNase I treatment, ssRNA was precipitated by lithium chloride or sodium acetate, incubated at −20 °C for 1 h, spun at 4 °C for 20 min, washed with 80% ethanol, and resuspended in water. After quantification, forward and reverse strands were mixed at a 1:1 ratio by weight and annealed by heating to 80 °C and then cooling slowly over 5 h to 35 °C. The concentration of the annealed RNA was measured, confirmed by gel electrophoresis, and stored at −80 °C until injection. Injections into larvae were carried out as described previously (26). Doses varying from 0.1 to 5.0 μg of dsRNA were diluted in injection buffer (5 mM KCl, 1 mM NaPO 4 , pH 6.9) to a total of 3 μL and injected into larvae during the third instar. We injected a total of 334 O. taurus (Ot-otd1, 251; Ot-otd1+otd2, 83), 312 O. sagittarius, 25 O. binodis, 91 D. gazella, and 138 L. militaris. Phenotype scoring is reported as number of dsRNA-injected beetles with ectopic eyes/total number of dsRNA-injected beetles that became pupae. Sham control injections were made exactly as described above, except that larvae were injected with 1 μg nonsense dsRNA from a 167-bp PCR product derived from a pBluescript SK vector. Transcription reactions, DNase I treatment, transcript annealing, and injections were performed as described above (160 O. taurus, 37 O. sagittarius, 23 O. binodis, 47 D. gazella, 60 L. militaris). Scanning Electron Microscopy. At least three adult individuals of each species and treatment were fixed in 70% ethanol, then incubated in 100% ethanol. Samples were either critical-point CO 2 dehydrated or immersed in hexamethyldisilazane and air-dried, coated with gold-iridium in an argon chamber, and imaged on either a JEOL JSM 5800 LV scanning electron microscope, or on a FEI Quanta 600, at 15 kV. Sectioning, Immunohistochemistry, and Confocal Imaging. Individuals at mid- to late pupal stage were cut between thorax and abdomen and fixed in PEM buffer (27) and then dehydrated by immersion in 100% methanol overnight. Samples were rehydrated in a decreasing methanol:PBS series and then moved through an increasing sucrose:PBS series until reaching 30% wt/vol sucrose. Samples were kept in sucrose over 1–2 d and then moved to OCT compound (Tissue-Tek, Sakura Finetek) and mounted on an aluminum stub at −20 °C inside a Reichert-Jung Cryocut 1800 cryostat. Samples were sliced to obtain sections between ∼18 and 25 μm thick, collected on glass slides, air-dried, and stored at −20 °C until used. For staining, samples were rehydrated in PBS and incubated in anti-acetylated α-tubulin antibodies, phalloidin, and DAPI as detailed elsewhere (28). Stained samples were imaged under a Leica SP8 laser scanning confocal microscope using LAS software. RNA Extraction and Sequencing. Whole animals were homogenized in TRIzol using disposable polypropylene RNase-free pellet pestles: For D. gazella, we used three individuals of each sex and late last larval instar, prepupa, first day pupa, and 4-d-old adult stages; for L. militaris, we only sampled a male prepupa and first day pupa. Chloroform was added to the homogenates in 1:5 volumes ratio, thoroughly mixed and incubated at room temperature for 2 min, and then spun at 13,600 × g. After centrifugation, the aqueous phase was transferred to a new tube and incubated at room temperature with an equal volume of isopropanol for 20 min; RNA was pelleted by centrifugation at 13,600 × g for 20 min at 4 °C, washed with 100% ethanol, air-dried, and resuspended in RNase-free water. Total RNA was quality checked using RNA ScreenTape TapeStation System (Agilent) and quantified with a Quant-iT RiboGreen Assay Kit (Thermo Fisher). RNA Stranded RNA-seq libraries were constructed using the TruSeq Stranded mRNA Sample Preparation Kit (Illumina) according to the manufacturer’s instructions. Libraries were quantified using a Quant-iT DNA Assay Kit (Thermo Fisher), pooled in equal molar amounts, and single-end sequenced on the NextSeq500 platform (Illumina) using a 75-cycle High Output Kit. Resulting 75-bp read sequences were cleaned using Trimmomatic version 0.32 (29) to remove adapter sequences and perform quality trimming. Trimmomatic was run with the following parameters: “2:20:5 LEADING:3 TRAILING:3 SLIDINGWINDOW:4:15 MINLEN:18.” Transcriptome Assembly and Annotation. The reference transcriptomes for D. gazella and L. militaris were assembled from 75SE reads using Trinity 2.0.6 (30) using “–trimmomatic–SS_lib_type R” parameters on a single 16 CPU node with 128 GB of RAM at the Mason computer cluster at Indiana University, Bloomington. Candidate coding sequences were predicted using Transdecoder 2.0.1 (transdecoder.github.io/), and the assemblies were annotated using the Trinotate pipeline (31) (https://trinotate.github.io/). The annotations were made based on Blast+ (32) searches against the UniProt database and current O. taurus genome annotations (21), HMMER (33) scans against the Pfam database (34), and predictions for signal peptides (35) and transmembrane domains (36). Differential Gene Expression Analysis. To compare the transcriptional profile of ectopic eyes to that of control posteromedial head epithelium and regular compound eyes, we dissected both tissues from control and Dg-otd1 dsRNA-injected females of D. gazella (Fig. 3A), and extracted total RNA following a previously described protocol (20), except that RNA was extracted directly out of the TRIzol reagent using Direct-zol RNA MiniPrep Plus spin columns (R2072; Zymo Research). RNA was processed using a TruSeq kit and sequenced on a NextSeq500 platform, as described above. We sequenced four biological replicates of each tissue and treatment. The resulting 75 bp single end reads were cleaned using Trimmomatic version 0.32 (29). Read alignment to the D. gazella reference transcriptome and transcript abundance estimation was performed using the align_and_estimate_abundance.pl and abundance_estimates_to_matrix.pl perl scripts included in Trinity r20140717 (30), using Bowtie2 (37) as alignment method and RSEM (38) as abundance estimation method. Differential expression analysis was performed by the DESeq2 (39) method (that uses a negative binomial model to perform pairwise Wald tests, adjusting for multiple testing using the Benjamini–Hochberg method) using Trinity v2.4.0’s run_DE_analysis.pl and analyze_diff_expr.pl scripts, including GO enrichment analysis by using the–examine_GO_enrichment parameter. The default P value cutoff for FDR of 0.001 was used. Tables of differentially expressed genes for each contrast were merged with the transcriptome annotation table described above using customized R (40) scripts. Cluster and correlation analyses were run on a log2-transformed matrix with an added pseudo count of one. A correlation matrix was computed with the Pearson method using R’s cor function, an Euclidean distance matrix was computed with the dist function, and hierarchical sample clustering was performed with the hclust function using the complete linkage method. A sample-to-sample correlation heatmap and dendrogram was generated using the heatmap.3 function bundled with Trinity v2.4.0. Scripts and data are available as Datasets S2–S11. Behavioral Testing of Ectopic Eyes Functionality. Testing of the ability of regular compound eyes and ectopic eyes to trigger a behavioral response took advantage of the aversive conduct toward sudden, strong light, shown by tunneling dung beetles when they are in a tunnel-like environment (41). Assays were conducted in a dark room and used a standard Petri dish (5.2 cm diameter) as arena to allow beetles to turn around and a cold-light dual gooseneck illuminator as light source. The light was blocked using a piece of folded tinfoil placed over the light output. To perform the test, a beetle was introduced into the Petri dish and allowed to acclimate for up to 10 min. Then the tinfoil plate located in front of the light source was carefully removed, followed by repeated blocking and unblocking of the light beam. This generated a strong, strobing light beam directed toward the beetle’s head. Wild-type beetles (B−I−; see Table S1 and Movie S1) react strongly to such exposure by stopping, lowering their head a few times, and quickly turning around and moving away from the light source. We therefore assessed the presence of a phototactic response by scoring whether beetles exhibited one or more of these behaviors: (i) slowing down (if in motion), (ii) stopping (if in motion), (iii) lowering of the head, and (iv) turning around and moving away from the light source. We generated individuals without lateral compound eyes (B+I−) by ablating eye precursor tissues at the late larval stage (14) and individuals without lateral compound eyes but possessing ectopic eyes by replicating ablations in Dg-otd1RNAi larvae (B+I+). The light aversion test was performed on 11 B−I−, 15 B+I−, and 12 B+I+ individuals. All four diagnostic behaviors (slowing down, stopping, head lowering, and moving away from the light source) were always exhibited in concert by wild-type animals and were entirely absent in B+I– individuals, whereas B+I+ individuals exhibited a mix of responses (Table S1). Percentages of B−I−, B+I−, and B+I+ individuals reacting to light were compared with z tests for the comparison of sampling proportions and Holm–Bonferroni correction.

Acknowledgments We thank Keeley Newsom, Justine Christian, Peyton Joachim, Bruno Buzatto, William Arnold, Shannon Close, Christopher Jacobsen, and Bonnie Young for beetle collecting and care; Barry Stein for assistance with electron microscopy; and James Ford and Jie Huang (Indiana University Center for Genomics and Bioinformatics) for help with RNA-seq. Yoshi Tomoyasu, David Linz, and two anonymous reviewers provided constructive comments on the manuscript. Light microscopy imaging was done at Indiana University Bloomington Light Microscopy Imaging Center; electron microscopy was done at the Indiana University Bloomington Electron Microscopy Center. Funding for this study was provided by National Science Foundation Grants IOS 1256689 and IOS 1120209 (to A.P.M.) and by an Indiana University STARS Undergraduate Fellowship (H.A.B.). Indiana University computing resources are supported by the National Science Foundation under Grants DBI-1458641, ABI-1062432, and CNS-0521433 to Indiana University.

Footnotes Author contributions: E.E.Z., A.L.M.M., H.A.B., and A.P.M. designed research; E.E.Z., A.L.M.M., H.A.B., and A.P.M. performed research; E.E.Z., A.L.M.M., and A.P.M. analyzed data; and E.E.Z., A.L.M.M., and A.P.M. wrote the paper.

The authors declare no conflict of interest.

This article is a PNAS Direct Submission.

This article contains supporting information online at www.pnas.org/lookup/suppl/doi:10.1073/pnas.1714895114/-/DCSupplemental.