The zebrafish smarcd2 gene was mutated by CRISPR/Cas9 technology using the method of Gagnon et al.51 (link). The web tool CHOPCHOP51 (link) was used to design gene-specific spacer sequences to contribute to two single-guide RNAs (sgRNAs) for smarcd2 targeting (named S1 and S2 in Supplementary Table 3). All CHOPCHOP results were checked against the zebrafish genome database using the Ensembl genome browser. DNA templates for sgRNA synthesis were generated by annealing of two single-stranded DNA oligonucleotides (Sigma-Aldrich) followed by T4 DNA polymerase (New England BioLabs) fill-in, to make a full double-stranded DNA oligonucleotide. For each sgRNA DNA template, one oligonucleotide provided the site-specific sequence (incorporating either S1 or S2) and the second ‘constant’ oligonucleotide supplied the binding site for the Cas9 enzyme. The sgRNAs were generated by in vitro transcription (mMESSAGE mMACHINE SP6 or T7 Transcription Kit, Thermo Fisher Scientific). Transcribed sgRNA was cleaned (Sephadex G-50 spin columns, Roche Diagnostics), and its integrity was checked on 1% agarose TBE gels (Bioline, BIO-41025). See the Supplementary Note for details on statistics.