Language proficiency predictors of code-switching behavior in dual-language-learning children

Code-switching, switching between different languages within the same conversation, is a prominent feature in bilingual communication. This study aimed to elucidate to what extent the linguistic abilities and age of dual-language-learning preschoolers influence the frequency and purposes of code-switching ( COMPENSATORY , to bridge linguistic gaps; PREFERENTIAL , to express content as fluently as possible; PRAGMATIC , to phrase something appropriately for the situation). Parental code-switching ratings of 101 German/French – Turkish/Italian dual-language learners aged 32 – 78 months were analyzed. Generalized linear mixed models revealed positive but no negative effects of societal-and heritage-language skills on children ’ s code-switching frequencies independent of switching purposes and with no evidence of age effects. Hence, code-switching across the preschool age mainly reflects high linguistic competences. Models with linguistically and psychometrically parallelized language scores indicated a strong switching tendency toward the societal language when proficiency in both languages is high, and away from the societal language when language proficiencies are low.


Introduction
Dual-language learning is considered an opportunity for societies' cultural enrichment (Berry, Phinney, Sam & Vedder, 2006). However, despite the growing acceptance of linguistic diversity within globalized societies, children vary greatly in the individual development of their dual-language competency and show difficulties in acquiring both their languages at similarly high levels (Dubiel & Guilfoyle, 2017;Sheng, 2014;Sheng, Lu & Kan, 2011). Although dual-language-learning children improve incrementally in their heritage-language abilities (Oppenheim, Griffin, Peña & Bedore, 2020), they typically become more dominant in their societal language as a consequence of increasing societal-language input at educational institutions (Dubiel & Guilfoyle, 2017;Sheng, 2014;Sheng et al., 2011). To support children's harmonious bilingual development, parents and childcare professionals strive to recognize favorable and unfavorable development patterns in both languages at an early stage (De Houwer, 2015;Hoff & Core, 2015;Kapantzoglou, Brown, Cycyk & Fergadiotis, 2021).
A commonly observed and salient feature of dual-language learners' discourse across the life span is the code-switching phenomenon: the ability of multiple-language learners to switch back and forth between different languages within the same conversation, incorporating words, phrases, or passages that originate from another language into an ongoing conversation (Poplack, 2001). Although code-switching has been investigated for decades, it remains unclear to what extent code-switching in young dual-language learners should be interpreted as a linguistic compensatory mechanism to bridge linguistic gaps or a shaping mechanism to make communication fluent or particularly appropriate to a situation (Ervin-Tripp & Reyes, 2005;Halpin & Melzi, 2021;Vu, Bailey & Howes, 2010;Yow, Tan & Flynn, 2018). Traditionally, code-switching in preschoolers has been assumed to be primarily a strategy for bridging lexical and syntactic gaps in one linguistic system with already acquired structures from the other system (Montanari, Ochoa & Subrahmanyam, 2019;Paradis & Nicoladis, 2007;Smolak, de Anda, Enriquez, Poulin-Dubois & Friend, 2019). Over the preschool years, as duallanguage skills and cognitive abilities increase with age, code-switching presumably develops into a communicative tool as an expression of pragmatic competence (Raichlin, Walters & Altman, 2019;Vu et al., 2010). Although, this assumption has not yet been subject to rigorous empirical testing, recent studies indicated that already in preschoolers' speech, code-switching is rather a sign of linguistic strength than weakness (Yow & Patrycia, 2015), implemented for similar purposes as those found in older children, adolescents, and adults (Auer, 1995(Auer, , 1998Halpin & Melzi, 2021).
Our goal was to extend the existing research on dual-language learning by investigating whether code-switching in preschoolers is a linguistic compensatory mechanism, a consequence of cross-lingual competition processes, a means of setting particular pragmatic accents, or a combination of different purposes. We examined how code-switching changes with increasing dual-language proficiency and we explored whether age, an indicator of cognitive maturation, can explain codeswitching frequency and purposes beyond linguistic effects. Finally, by controlling for both language competencies we attempted to clarify if dual-language-learning children tend to switch asymmetrically toward one language, suggesting that already preschoolers assign differential values to their languages.

Mechanisms and purposes of children's code-switching
Early models of dual-language learning such as the unitary language system hypothesis (Volterra & Taeschner, 1978) see code-switching merely from a deficit-oriented perspective. Accordingly, young dual-language learners are not yet capable of distinguishing between their languages, choosing indiscriminately the language with the accessible representation of the content they aimed to express. More recent linguistic approaches like the Ivy Hypothesis (Bernardini & Schlyter, 2004) still focus on communicative problems as a cause for code-switching but emphasize its strategic character as a linguistic gap-filling approach. Accordingly, young linguistically-unbalanced duallanguage learners use the morphosyntactic structures of the stronger language to expand the limited morphosyntactic expression in their weaker language. Hence, lexical expressions and syntactic structures of the weaker language grow like "ivy on the structural tree of the stronger language" (Bernardini & Schlyter, 2004;p. 49). Since dual-language learners handle the acquisition of two languages at the same time in which single-language learners concentrate on one language, they may develop linguistic skills in each language comparably slower (Poulin-Dubois, Bialystok, Blaye, Polonia & Yott, 2013). Although most linguistic gaps disappear when considering the combined linguistic repertoire of both languages (Legacy, Zesiger, Friend & Poulin-Dubois, 2018;Poulin-Dubois et al., 2013), not all linguistic representations are available in both languages. Hence, when dual-language learners experience linguistic gaps in the conversational language they mayaccording to the Ivy Hypothesisfall back on the switchover language, resulting in COMPENSATORY CODE-SWITCHING (Montanari et al., 2019;Paradis & Nicoladis, 2007;Smolak et al., 2019). Empirical evidence endorses that children code-switch when they lack a translation equivalent (i.e., synonym across languages) or have difficulties constructing appropriate grammatical structures in the weaker language (Bernardini & Schlyter, 2004;Greene, Peña & Bedore, 2013). However, both hypotheses fail to explain why code-switching still occurs after the initial dual-language-learning phase and beyond the course of communicative difficulties (Halpin & Melzi, 2021;Rodriguez-Fornells, Kramer, Lorenzo-Seva, Festman & Münte, 2012;Yow & Patrycia, 2015).
Cognitive models of code-switching, as the Control Process Model (Green, 2018;Green & Wei, 2014) provide a comprehensive theoretical framework for code-switching beside compensatory purposes. A central assumption is that the two languages of dual-language learners are co-activated. The language use in a specific situation is seen as the outcome of a hidden competition between linguistic representations of both languages within a joint dual-language network. The Control Process Model postulates that a concept is verbalized in the language in which the corresponding linguistic representation is faster retrieved (Green & Wei, 2014), leading to PREFERENTIAL CODE-SWITCHING. This preferential code-switching seems to be exercised already by young dual-language-learning children who unintentionally use the stronger activated linguistic representation of the nonconversational language to fluently convey conversational content, despite actually having a sufficient linguistic repertoire in the conversational language (Halpin & Melzi, 2021;Yow & Patrycia, 2015;Yow et al., 2018). Thereby, the grammatical structure of the conversational language is often retained when using words or phrases from the non-conversational language, demonstrating linguistic dexterity in both languages (Halpin & Melzi, 2021). Within cognitive models, the competitive process behind code-switching is described as situational but also cognitively controlled. According to the Adaptive Control Hypothesis (Green & Abutalebi, 2013) dual-language learners exert different control processes depending on the language environment. In settings with a separate language use, the competitive language control is activated. The current conversational language is focused, releasing mainly utterances from the appropriate language. However, in settings where code-switching is accepted, cognitive control processes allow a cooperative language use.
Aforementioned cognitive models corroborate the assumption that code-switching might not be a mere consequence of language proficiency; it might also rely on cognitive functions that are still developing during early childhood. Improved cognitive control processes as well as deeper pragmatic and metalinguistic knowledge are probably the basis for another form of code-switching often described in older children: intentional switches to create a meaningful linguistic effect or to follow pragmatic rules referred to as PRAGMATIC CODE-SWITCHING (Auer, 1998;Raichlin et al., 2019). It is used to retell a previous conversation in the corresponding language or to quote someone in the respective language (Auer, 1998;Ervin-Tripp & Reyes, 2005;Raichlin et al., 2019). Further, pragmatic code-switching is employed to clarify, repeatedly explain, or repair communication in case of misunderstanding or even lack of understanding on the interlocutor's behalf (Auer, 1998;Vu et al., 2010).
Dual-language proficiency as predictor of children's code-switching behavior During childhood, code-switching likely underlies qualitative development (Montanari et al., 2019;Smolak et al., 2019). Whereas toddlers and preschoolers supposedly perform compensatory or preferential code-switching (Montanari et al., 2019;Paradis & Nicoladis, 2007;Smolak et al., 2019), school-aged children are assumed to also engage in pragmatic code-switching (Raichlin et al., 2019). Dual-language fluency is presumably the driving force for compensatory and preferential code-switches (Montanari et al., 2019;Smolak et al., 2019;Yow et al., 2018). Indeed, evidence indicates that young children with discrepant language proficiencies code-switch to the dominant language when they lack a translation equivalent or have difficulties constructing appropriate grammatical structures in the nondominant language (Greene et al., 2013;Montanari et al., 2019;Ribot & Hoff, 2014;Smolak et al., 2019). Studies examining the relationship of typically developing preschoolers' dual-language proficiencies together with code-switching on a metric level have shown positive (Montanari et al., 2019;Yow et al., 2018) and negative (Kapantzoglou et al., 2021;Montanari et al., 2019;Smolak et al., 2019) associations between language competency and code-switching frequency. The authors interpreted positive associations as evidence that with increased proficiency in the nonconversational (i.e., switch-over) language, code-switching out of the conversational language into this proficient switch-over language occurs more frequently (Montanari et al., 2019;Yow et al., 2018). The negative associations were attributed to the fact that with a weak conversational-language proficiency, more frequent code-switches occur out of the conversational language into the switch-over language (Kapantzoglou et al., 2021;Smolak et al., 2019). In this view, preschoolers' code-switching seems to entail both compensatory and preferential components (Auer, 1995(Auer, , 1998Halpin & Melzi, 2021). Reported findings based on regression analyses are consistent with studies investigating the same relationship on a group level (Montanari et al., 2019;Ribot & Hoff, 2014). These group-level findings moreover indicate that a substantial proportion of young dual-language learners show no code-switching at all (Montanari et al., 2019;Ribot & Hoff, 2014). In these children, a positive effect of the switch-over language presumably attracts a switch, and in turn, a negative effect of high conversational-language proficiency precludes a switch, leading to compensatory and preferential code-switching potentially canceling each other out.
Changes in young dual-language learners' code-switching behavior are likely influenced by both linguistic and cognitive development (Green, 2018;Green & Wei, 2014). As children's language skills grow stronger, they presumably experience fewer linguistic gaps and, therefore, engage in less fluency-related compensatory code-switching (Montanari et al., 2019;Smolak et al., 2019). Likewise, with increasing age, children are supposedly better able to control inappropriate preferential activations of a language (Garon, Smith & Bryson, 2014). During this linguistic and cognitive development, children experience a process of representational redescription; that is, the process of gaining explicit knowledge about long-acquired implicit linguistic routines, leading them to reflect metalinguistically on language structure and language use in specific situations (Karmiloff-Smith, 1994). This might explain why pragmatic code-switching is primarily reported in older children (Raichlin et al., 2019).
Still, in Halpin and Melzi's (2021) longitudinal study no indication of qualitative changes in preschoolers' code-switching purposes was found, pragmatic code-switching was already apparent to a substantial degree, endorsing that linguistic-context sensitivity becomes established very early in children's development (Comeau, Genesee & Mendelson, 2007). However, it is important to note that language-proficiency effects were mostly investigated separately for both languages, resulting in either compensatory or preferential effects. Moreover, existing studies did not disentangle the language-proficiency and age effects on different codeswitching purposes. Concomitant positive and negative effects of dual-language proficiency and age effects on code-switching behavior might be identifiable only when simultaneously included in a regression model.

Code-switching asymmetries in children
Children's code-switching behavior also shows unexpected switching patterns to a weaker language (i.e., asymmetrical code-switching) not explainable by linguistic abilities alone (Montanari et al., 2019;Ribot & Hoff, 2014;Smolak et al., 2019). A possible explanation for such asymmetrical code-switching might be the broader societal context. Some researchers have assumed that even young children exhibit context-sensitive code-switching influenced by the societal majority language (Montanari et al., 2019;Ribot & Hoff, 2014;Smolak et al., 2019). Dual-language-learning children may experience acculturation-related stress as they simultaneously acquire competences in the heritage and the societal culture and learn to adapt their behavior between cultural contexts (Berry, 2015;Kinzler, Shutts, DeJesus & Spelke, 2009). In many monolingual societies, dual-language learners have a higher risk of experiencing exclusion and discrimination because of divergent linguistic backgrounds (Kinzler et al., 2009). A substantial number even reduce their heritage-language use in order to adapt (De Houwer, 2021). Hence, dual-language-learning children presumably show less code-switching to the infrequent and less prestigious heritage language when communicating in the societal language, and display more code-switching to the more frequent and prestigious societal language during heritage-language conversations (Montanari et al., 2019;Ribot & Hoff, 2014). This assumption was explicitly investigated by Smolak et al. (2019), who analyzed code-switching in two different regions. In California, U.S. English is the socially relevant language and Spanish the heritage language of a minority group. In Québec, Canada, the societal language is French but English is also widely used. In both regions, dual-language-learning children showed a switching preference toward English (Smolak et al., 2019). The authors concluded that English is (in California) or is becoming (in Québec) a prestigious language, leading to more frequent code-switches into English. However, in these studies, the children's language competencies were not controlled for in a way that allowed asymmetrical code-switching to be interpreted as an effect solely driven by the broader societal context. These difficulties in interpretation might stem from the extremely high psychometric requirements of such research questions (Bedore et al., 2012). Although many code-switching studies are carried out at great expenditure of time and effort, the requirements of linguistically and psychometrically equivalent language tests as predictors of code-switching direction have, to the best of our knowledge, not yet been accomplished. To determine an asymmetrical tendency of dual-language-learning children to switch more to a prestigious language, it is crucial to investigate whether linguistically-balanced children who speak both languages at comparable levels rather switch to the more prestigious language, and, whether children with the prestigious language being nondominant also switch more frequently than anticipated based on their language skills to this non-dominant language. A main obstacle here is the determination of equivalent language competence. Even with internationally established standardized instruments like the Peabody Picture Vocabulary Test (Dunn & Dunn, 2007), it cannot be assumed that test items across various languages are indeed equivalent in terms of difficulty, reliability, and validity.

The present study
We sought to investigate preschooler's code-switching behavior in relation to dual-language proficiency and age. We studied duallanguage learners growing up in Switzerland and Germany acquiring the societal language German or French together with the heritage language Italian or Turkish. The transfer to the European context expands contemporary code-switching literature, as most previous studies investigated code-switching behavior with language combinations including English (Kapantzoglou et al., 2021;Montanari et al., 2019;Ribot & Hoff, 2014;Smolak et al., 2019;Yow & Patrycia, 2015;Yow et al., 2018).
The present study captured code-switching by asking parents to explicitly rate possible purposes of their children's code-Bilingualism: Language and Cognition switching behavior, specifically inquiring about the directions of the code-switch (i.e., from societal to heritage language and vice versa) and the underlying purposes (i.e., compensatory, preferential, and pragmatic). This allowed us to identify differences in preschoolers' use of different code-switching forms as a function of language proficiencies and age.
Moreover, we assessed children's dual-language competences with parallelized test instruments in terms of linguistic content and psychometrical properties. To the best of our knowledge, this is the first study investigating code-switching frequency by concomitantly incorporating both language proficiencies, both possible code-switching directions, as well as potential underlying purposes in a regression analysis. This approach allowed us to parsimoniously model the complex interplay of the two language competencies and age in the emergence of different directions and purposes of preschoolers' code-switching. Furthermore, linguistically and psychometrically parallelized language tests allowed us to model whether children show a code-switching tendency to the more prestigious societal language. To develop a nuanced picture of dual-language-learning preschoolers' code-switching behavior across language abilities, we tested three hypotheses: Hypothesis 1: Children's code-switching behavior is positively and negatively affected by dual-language proficiency. Given the findings from previous studies, we expected positive effects of the proficiency in language A on the code-switching frequency into this language A. At the same time, we also expected negative effects on switching frequencies out of this language A into language B. We expected this same pattern for societal-and heritagelanguage proficiency alike.
Hypothesis 2: Children show different code-switching purposes as a function of linguistic proficiency and age. We sought to identify diverse purposes in children's code-switching in relation to their dual-language competence. Thus, we tested the assumption that dual-language proficiency and age modify code-switching purposes. As children with higher language skills develop explicit knowledge about language use, and older children who are approaching school age become cognitively mature, we expected pragmatic code-switching to increase with higher dual-language competence and age, but still to be comparatively rare on average compared to other purposes.
Hypothesis 3: Dual-language learners show asymmetries in code-switching direction, with a tendency toward the societal language. Finally, we turn to the question of whether dual-language learners have an asymmetrical bias toward one of the two languages regardless of their proficiencies. Previous studies have provided inconsistent findings, with tendencies toward English as the more prestigious language (Smolak et al., 2019). However, the language tests have not been controlled for psychometric and linguistic equivalence to determine language balance. We strictly parallelized the language scores in terms of linguistic content and psychometric properties. Given previous findings, we expected that children with balanced abilities across all proficiency levels would tend to switch to the more prestigious societal language. For linguistically-unbalanced children, we expect the switching tendency toward the dominant language to be lower in children with a heritage-language dominance compared to children with a societal-language dominance.

Methods
This study was embedded in an international and interdisciplinary multi-site longitudinal research project in Switzerland and Germany. The main objective of this large-scale study was to investigate the linguistic, cognitive, and socioemotional development of children growing up in a single-or dual-language environment. In Germany, the only societal language is German, whereas in Switzerland exist four societal languages which are separated geographically. We investigated the two most prominent ones which are German (including Swiss-German variants) and French, spoken by 62% and 23% of the population, respectively (Bundesamt für Statistik, 2021a). The project focused on dual-language learners acquiring the heritage language Turkish or Italian, first to guarantee the assessment of the heritage language and second, to provide fair test instructions for linguistic and non-linguistic tests (e.g., IQ scores) in the child's most proficient language. The heritage languages were chosen based on their high frequency in Switzerland and Germany (Bundesamt für Statistik, 2021b; Zensus, 2011), historically explicable by the immigration of guest workers (Bade, 2013;Eidgenössische Migrationskommission, 2020;Haab, Bolzman, Kugler & Yılmaz, 2010). Moreover, there are also differences between the groups regarding acculturation. Turkish minority groups in Central Europe seem to struggle to achieve high educational qualifications and to learn the language of the community, and children even experience discrimination and exclusion (Froehlich, Mok, Martiny & Deaux, 2022), which seems less pronounced among the Italian-speaking minority (Makarova, 2014).
Children's data were assessed individually with a playful testing battery. To gain comprehensive insights into children's behavior, information about rare and highly context-dependent behavior (e.g., code-switching, social behavior) was assessed through questionnaire-based parent and/or educator reports. In total, 389 single-and dual-language-learning children participated in the large-scale project between October 2019 and February 2020 and between August 2020 and April 2021. Children were recruited through childcare facilities and advertisements. Parents' written informed consent was given prior to the children's testing. Participating families and educators received a reimbursement of expenses. Parents reported their children had normal or corrected-to-normal hearing and vision and had never been diagnosed with cognitive impairments, pervasive developmental disorder, or separation anxiety disorder. As the assessment of developmental language disorders in dual-language-learning children is complex, it was not an exclusion criterion (Nayeb, Lagerberg, Sarkadi, Salameh & Eriksson, 2021). Rather, one goal of the larger project is to improve its diagnosis in dual-language-learning children. Nevertheless, none of the children presented here was diagnosed with a language disorder. The project has been evaluated as unobjectionable by the Swiss ethics committee Ethikkommission Nordwest-und Zentralschweiz (EKNZ; Req-2020-00504).

Participants
Although part of the large-scale project, this study focused on a subsample consisting of dual-language learners with available code-switching data. The parental questionnaire assessing code-switching was completed for 69% of the dual-language learners (106 of 155). To ensure that parental assessments were based on firsthand experience, it had to be evident that the societal language was used at least occasionally in the family context. Five preschoolers were excluded from further calculations because of lacking societal-language use at home. Despite the moderate questionnaire response rate, the drop-out rate in this study was unselective. Children with parental reports on code-switching did not differ from those without available code-switching data in age, sex, linguistic or nonverbal skills, parental educational background, or other relevant family factors. A significant effect was found only for heritage-language background. Here, significantly more code-switching questionnaires were available for Italian-speaking than for Turkish-speaking children (odds ratio of 3.41).

Measurements
Children's code-switching behavior The parental code-switching questionnaire was constructed with items adapted from the established bilingual switching questionnaire (Rodriguez-Fornells et al., 2012) and the code-switching attitude and behaviors questionnaire (Kharkhurin & Wei, 2015) assessing adults' code-switching, and self-created single questions assessing code-switching in children (Bosma & Blom, 2019;Ribot & Hoff, 2014). To determine whether code-switching occurs, the initial question was "Does your child switch between languages when (s)he speaks to another bilingual person?". After a total revision of the parent questionnaire (COVID break: March 2020 until July 2020), the initial question was also differentiated by code-switching direction ("Does your child switch languages when speaking from German/French to Italian/Turkish?" and "Does your child switch languages when speaking from Italian/ Turkish to German/French?"). In both cases, if parents rated their child's code-switching behavior as never, they skipped the following items which were scored with zero. Otherwise, parents received among other questions assessing different aspects of children's code-switching behavior six questions specifically evaluating each code-switching direction. Parents who received the initial questions differentiated by code-switching direction (49.5%) did not differ in social background variables, frequency of reporting no code-switching, or further code-switching ratings.
The six code-switching questions assessed each code-switching purpose per code-switching direction.
(1) Compensatory code-switching: a. "When (s)he cannot remember a word/phrase/sentence in German/French, (s)he says it in Italian/Turkish." b. "When (s)he cannot remember a word/phrase/ sentence in Italian/Turkish, (s)he says it in German/ French." (2) Preferential code-switching: a. "When (s)he wants to formulate something in German/ French, (s)he says it unintentionally in Italian/Turkish, because it occurs to him/her faster." Note. HLA = Heritage language; SLA = societal language. a Due to the young sample in this study, simultaneous dual-language learners are described as children who acquire both languages since birth, any time discrepancy is considered as successive dual-language learning. b Italian-speaking children were significantly younger than Turkish-speaking children. c Standardization sample of children's nonverbal IQ scores: M = 10, SD = 3.00. d Italian-speaking children had significantly higher parental education than Turkish-speaking children. e Mothers of Italian-speaking children had a significantly higher self-rated societal-language proficiency.
Bilingualism: Language and Cognition 5 b. "When (s)he wants to formulate something in Italian/ Turkish, (s)he says it unintentionally in German/ French, because it occurs to him/her faster." (3) Pragmatic code-switching: a. "Although (s)he knows a word in German/French, (s)he says it in Italian/Turkish to express herself/himself better or to create a special effect." b. "Although (s)he knows a word in Italian/Turkish, (s)he says it in German/French to express herself/himself better or to create a special effect." These items were rated on a 4-point Likert scale (0-3) with the answer options does not apply (0), does rather not apply (1), does rather apply (2), does apply (3).
Children's language proficiency Children's proficiency in their societal and heritage language was based on their performance in standardized tasks assessing productive and receptive vocabulary as well as sentence comprehension. All language tests were compiled on the basis of existing standardized language test items and were optimized to ensure that the four languages studied were assessed with the same linguistic content and an equally high degree of consistency and reliability. Each language test consisted of an item pool of 32 items. A quarter of the 32 items in one language (e.g., German) were original items from an established language assessment tool (e.g., German original item hoof). Another quarter were translation equivalents within the societal or heritage language (e.g., French translation of hoof). In a final step, new items (i.e., twin items) were created out of the established language items for the respective other heritage or societal languages (e.g., new linguistically parallel item fin for Italian and Turkish). For further details see Appendix 1. All tests followed an adaptive testing principle based on the children's response accuracy in a routing test (Lord, 1971). Children first got 16 moderately difficult items within a routing set with ascending difficulty order. Children who frequently failed in the routing set subsequently received eight easier items. If they successfully answered most routing items eight more difficult items followed. Children in the medium range answered four difficult and four easy randomly selected items.
Productive vocabulary. During the productive vocabulary task, children saw pictures and were asked to name them in the target language. Original items were selected from the German assessment tool Active Vocabulary Test for 3-to 5-Year-Old Children (Kiese-Himmel, 2005), the French assessment tool evaluation of oral language (Khomsi, 2001), the Italian assessment tool Lexical neuropsychological test for developmental age (Cossu, 2013), and the Turkish assessment tool Turkish Expressive and Receptive Language Test (Berument & Güven, 2013). Both the Cronbach's alpha of the 16 routing items (α Routing societal language = .79; α Routing heritage language = .69) and the standardized factor loadings of the overall test (overall societal language λ = .50; overall heritage language λ = .79) indicate a high reliability of the language tests.
Receptive vocabulary. Throughout the receptive vocabulary task children heard a word and had to choose the correct picture out of four. The items originated from the German and Italian versions of the Peabody Picture Vocabulary Test (Lenhard, Lenhard, Segerer & Suggate, 2015;Stella, Pizzoli & Tressoldi, 2000), the French assessment tool Computerized oral language battery for cycle 2 (Khomsi & Khomsi, 2007), and the Turkish assessment tool Turkish Expressive and Receptive Language Test (Berument & Güven, 2013). The Cronbach's alpha of the 16 routing items (α Routing societal language = .78; α Routing heritage language = .68) and the standardized factor loadings of the overall test (overall societal language λ = .58; overall heritage language λ = .60) indicate a high reliability of the language tests.
Sentence comprehension. Also in the sentence comprehension task children heard a sentence and had to select the correct picture out of four. Original sentence comprehension items were derived from the German and Italian versions of the Test for Reception of Grammar (Bishop, Suraniti, Ferri & Neri, 2009;Fox-Boyer, 2006), the French assessment tool test of syntacticsemantic comprehension (Lecocq, 1998), and the Turkish assessment tool Turkish Early Language Development Test (Topbas & Guven, 2011). The Cronbach's alpha of the 16 routing items (α Routing societal language = .72; α Routing heritage language = .67) and the standardized factor loadings of the overall test (overall societal language λ = .60; overall heritage language λ = .56) indicate a high reliability of the language tests.
Scaling. Since in an adaptive design with planned missing values, items cannot simply be summed up, for each test expected a posteriori factor scores were estimated based on a two-parameter item response model (Estabrook & Neale, 2013). To achieve the highest possible generalizability of the scores and to control for potential cross-linguistic interference and transfer effects, the measurement parameters were tested for scalar measurement invariance across all assessed language groups. Hence, all items and their translations were tested for whether there were similarly high factor loadings and item threshold values within each group (details in Appendix 2). This also excluded the possibility that systematic cross-linguistic interference or transfer effects could affect measurement quality in specific groups of dual-language learners. Productive and receptive vocabulary and sentence comprehension scores were standardized and averaged forming one comprehensive composite societal-and one heritage-language score each.
In a final step, to generate linguistically and psychometrically parallelized societal-and heritage-language scores for hypothesis 3 regarding code-switching asymmetry, the factor loadings and thresholds of the original societal-or heritage-language items and those of the corresponding linguistically parallel-constructed twin items in the respective other languages were fixed and tested for equality. This ensured that both societal-and heritagelanguage scores reflected equally strong items with the same linguistic structures. For example, the French/German societallanguage item hoof and the new linguistically parallel Italian/ Turkish twin item fin were estimated to have the same factor loadings and thresholds. Again, scaling was done by estimating factor scores. In this way, linguistically and psychometrically comparable societal-and heritage-language scores could be estimated for each child, even if the child had not completed all items due to the adaptive test-design (details in Appendix 2) and Segerer, Schächinger Tenés, Bühler & Grob, 2021.

Procedure
Language skills were assessed in blocks, first, all language tests in the language identified as dominant by the parents, followed by all tests in the non-dominant language. This sequence was designed according to three principles: (a) Children should feel comfortable right from the beginning. (b) Children should concentrate on one language only and not switch from one language to another during testing. Nevertheless, (c) we still wanted to avoid sequence effects. After piloting studies to rule out effects of test order, we established a fixed sequence starting with children's dominant language to ensure a comfortable beginning. Children's code-switching data were collected via parental questionnaires.

Analyses
The analyses addressing the main research questions were conducted using generalized linear mixed models in the statistical program R (version 4.2.1.; R Core Team, 2022). A key advantage of this method is that within-person variance can be explained by item properties (i.e., Level 1) and simultaneously also betweenperson variance by person properties (i.e., Level 2). Interactions of these Level 1 and Level 2 predictors can be modeled additionally (Gałecki & Burzykowski, 2013). Since our dependent variable code-switching frequency was measured using a four-point rating scale and the response pattern was non-symmetric but markedly over-dispersed, the discrete beta-binomial distribution was chosen as the error distribution (Schmettow, 2021). Generalized linear mixed models were estimated using the R package brms (version 2.17.0; Bürkner, 2017). A logit-link function was used to estimate linear effects of the predictor variables on log-cumulative odds of the code-switching ratings, that is the natural logarithm of the odds ratio to obtain a code-switching rating at a certain level compared to levels below.
To elucidate the role of item characteristics for variation in children's code-switching behavior, we analyzed the item-specific effects code-switching direction and purpose. To explain code-switching differences between children we investigated effects of child properties, particularly heritage-and societallanguage proficiency, and age. Three different generalized linear mixed models were conducted. In the first model (Hypothesis 1), we investigated how children's code-switching frequency either in the direction of the societal or the heritage language was affected by societal-and heritage-language proficiencies. We included dummy-coded code-switching direction (1 = societal to heritage language, 0 = heritage to societal language) and compensatory (1 = compensatory, 0 = other purposes) and pragmatic (1 = pragmatic, 0 = other purposes) code-switching purposes as itemlevel predictors of our six code-switching items. Our main predictors were standardized language-proficiency scores. Since we expected opposed effects of language skills for each switching direction, our main focus was on interaction effects with code-switching direction. The societal-(1 = German, 0 = French) and heritage-language background (1 = Turkish, 0 = Italian) served as dummy-coded control variables together with children's sex (1 = girls, 0 = boys) and age. To test Hypothesis 2 (Model 2), that pragmatic code-switching gains in importance compared to other purposes with increasing language proficiencies and age, we added to Model 1 three-way interactions of language proficiencies, direction, and purposes and also two-way interactions of age and purposes.
For Hypothesis 3 regarding an assumed code-switching tendency in favor of the prestigious societal language, the code-switching frequencies for both directions were estimated. For this purpose, the linguistically and psychometrically parallelized societal-and heritage-language scores were used in the regression model that had fitted the data best (Model 1 or 2). Since it was not clear whether a parallelization of the scores could also be assumed for composite score, these analyses were carried out separately for each of the three language domains productive and receptive vocabulary and sentence comprehension. First, the main effect of code-switching direction was analyzed. The societal-and the heritage-language score were first centered on the mean societal-and subsequently on the mean heritage-language score. The resulting effects of direction can then be interpreted as the estimated differences in switching frequencies toward the societal or the heritage language when both language skills are equally developed at an average skill-level. Second, by summing up the anticipated positive and negative effects of the societal and heritage language for each code-switching direction, we calculated expected code-switching frequencies for children with balanced languageproficiency scores across the entire range of the proficiency scales. The distance between these two lines was used to assess whether the anticipated switching tendency toward the more prestigious societal language would only occur at specific levels of balanced dual-language abilities. An analogous approach was chosen to model switching tendencies in linguisticallyunbalanced children. Here, code-switching was estimated for children with a difference between both languages of one standard deviation, either in favor of the societal or the heritage language (details in Appendix 3).
All generalized linear mixed models were conducted with subject-wise random slopes and intercepts. Models presenting the most explained variance accompanied by the lowest value of the Watanabe-Akaike information criterion (WAIC) and the leave-one-out cross-validation information criterion (LOOIC) fit indices indicated best fit to the data (Nalborczyk, Batailler, Vilain & Bürkner, 2019).

Descriptive statistics and correlational analysis
As reported in detail in Table 2, there were no significant correlations between the six individual code-switching ratings and children's sex or age. In contrast, children's societal-and heritage-language-proficiency measures as well as language backgrounds were significantly associated either positively or negatively with the children's code-switching ratings. In terms of language proficiencies, it becomes evident that both language proficiencies increase with age, and that children's language background matters. The two heritage-language groups differed significantly in their societal-language proficiency with Italianspeaking children being more proficient than Turkish-speaking peers (t(91.21) = 3.97, p < .001, d = 0.38). However, groups did not differ in their heritage-language proficiency (t(90.51) = 1.24, p = .23). Focusing further on the Italian-speaking children (French vs. German) revealed no significant differences in societal-(t(49.79) = −1.35, p = .18) or heritage-language proficiencies (t(45.23) = −0.13, p = .90).

Is children's code-switching behavior affected by dual-language proficiency?
Model 1 analyzing dual-language learners' language proficiencies and their interaction with code-switching as main predictors explained 69% of the variance in code-switching (R 2 = .69, WAIC = 1,054.26, LOOIC = 1,076.77). We found significant interaction effects of the code-switching direction with societal-and heritage-language skills (specific results in Table 3). Simple

Bilingualism: Language and Cognition
slope analyses further examined the interactions of codeswitching direction with societal-and heritage-language skills. For code-switches from the societal to the heritage language, no societal-language effect was found (b = −0.34; SE = 0.30; 95% CI [−0.94, 0.24]; p = .18; Figure 1, solid line). A higher societallanguage proficiency was not significantly associated with less switching to the heritage language. In turn, the heritage language showed a positive association indicating that the better the heritage-language proficiency the more code-switching to the heritage language occurred (b = 0.71; SE = 0.30; 95% CI [0.13, 1.33]; p = .02; Figure 2, solid line). Code-switches from the heritage to the societal language showed the same pattern. Higher societal-language proficiency resulted in more code-switching to the societal language (b = 1.61; SE = 0.34; 95% CI [0.95, 2.30]; p < .001; Figure 1, dotted line), whereas heritage-language proficiency did not significantly affect switches to the societal language (b = −0.60; SE = 0.33; 95% CI [−1.25, 0.04]; p = .07; Figure 2, dotted line).
Are code-switching purposes a function of linguistic proficiency and age?
In Model 2, we checked whether pragmatic code-switching became more prominent with higher language proficiency and age than other purposes. Therefore, we integrated three-way interactions of language proficiencies, direction, and purposes and also two-way interactions of age and purposes into the model. Although the likelihood ratio test suggested a significantly better fit of Model 2, the explained variance increased only by 1%. Concomitantly, the information criteria indicated no substantial rise in goodness of fit (R 2 = .70, AIC = 1,056.00, LOOIC = 1,081.46). No significant two-or three-way interactions were found. The parent-based ranking of code-switching purposes, with compensatory code-switching in first place, preferential code-switching in second place, and pragmatic code-switching being least frequent, was found regardless of language proficiency or age.
In additional analyses, neither quadratic language-proficiency terms nor children's nonverbal IQ, societal-or heritage-language exposure, parents' highest education or parents' self-rated language proficiencies were incremental predictors of code-switching frequencies or moderated direction and/or purpose effects.
Do dual-language learners show asymmetries in code-switching direction with a tendency toward the societal language?
To test Hypothesis 3, we aimed to understand whether children tended to code-switch toward the societal language by controlling for actual proficiency differences between the societal and heritage language. To ensure a valid comparison of the societal-and heritage-language skills, only linguistically parallelized items with equivalent measurement properties were used to estimate language proficiencies. This was done separately for each language domain, namely receptive and productive vocabulary and sentence comprehension. Our sample showed higher heritage-than societal-language skills. This was evident in all three language subdomains with variable effect size (d receptive vocabulary = 0.48; d productive vocabulary = 0.43; d sentence comprehension = 0.94). If children with a skill difference of less than one standard deviation are defined as linguistically-balanced, thendepending on the three language subdomains -29-68% of the children were Table 2. Descriptive statistics and Pearson correlation analysis of the code-switching and language proficiency variables together with the control variables sex, age, and societal-and heritage-language background. balanced, 6-25% showed societal-language dominance, and 27-46% heritage-language dominance. In our modeling approach, we estimated directional asymmetries in code-switching frequency for children with exactly the same level of societal-and heritage-language competence. Across the three different language subdomains there was no consistent evidence that code-switching into one language occurred more frequently than into the other (range of direction effects: b = −0.17 to 1.30). However, we found an imbalance in the positive and negative effects promoting or preventing switches from a conversational language into a switch-over language. For switches from the societal to the heritage language, neither societal-(b = −0.65 to −0.40) nor heritage-(b = 0.29 to 0.85) language skills showed consistent significant effects. Similarly, for code-switches from the heritage to the societal language, there were no consistent significant negative heritage-language effects (b = −0.79 to −0.36). However, we found consistently significant strong positive effects of societal-language skills across language subdomains on switching to the societal language (b = 1.31 to 1.43). Although, this suggests no general code-switching tendency toward the prestigious societal language, code-switches toward the societal language seemed particularly strongly linked to children's actual societal-language competence. To illustrate this asymmetrical code-switching pattern comprehensively, we combined the results of the three language subdomains (i.e., intercepts and slopes of the positive and negative societal-and heritage-language effects) in Figure 3. Balanced children with average proficiency in both languages show no code-switching tendency toward one language. However, due to the very strong positive effect of societallanguage skills, code-switching to the societal language seemed to occur more frequently than switches to the heritage language when balanced children showed above-average proficiency levels in both languages, and less frequently in balanced below-average children.

Variable
Unbalanced dual-language-learning children switched preferentially toward their dominant language regardless whether this was the prestigious societal (range of direction effects: b = −0.30 to −2.11) or the heritage language (range of direction effects: b = 0.73 to 1.79). Due to the very strong positive effect of societallanguage skills, the code-switching preference toward the societal language was particularly large if the societal language was not only dominant but highly pronounced. A heritage-language tendency resulted especially when the heritage language was not only dominant but the societal-language skills were particularly low. In Appendix 3, this is exemplified for unbalanced duallanguage learners with a difference between societal-and heritage-language skills of exactly one standard deviation. Note. In this model, child's characteristics sex, age, societal-language background (French or German) and heritage-language background (Italian or Turkish) were accounted for together with the main predictors of societal-and heritage-language proficiency. Compensatory and pragmatic refer to the code-switching purposes. CI = Confidence interval; CS = code-switching; HLA = heritage language; SLA = societal language. Fig. 1. The interaction effect of code-switching direction with societal-language proficiency. Note. The interaction effect of code-switching direction and z-standardized societal-language proficiency with 95% confidence intervals.
Bilingualism: Language and Cognition 9

Discussion
We investigated to what extent code-switching behavior of dual-language-learning preschoolers to the societal or heritage language can be understood as a compensation mechanism to bridge linguistic gaps, a shaping mechanism to make communication fluent or particularly appropriate to a situation, or a combination. Further, we analyzed whether these purposes changed with increasing language proficiencies and explored whether age as an indicator of cognitive maturation could explain code-switching purposes beyond dual-language-competence effects. Finally, we investigated whether children showed a tendency toward the more prestigious societal language. These research aims were investigated using a large sample of dual-language-learning preschoolers from Germany and Switzerland either speaking German or French with Italian or Turkish. Using a generalized linear mixed model approach, we simultaneously investigated the positive and negative effects of societal-and heritage-language Note. The interaction effect of code-switching direction and z-standardized heritage-language proficiency with 95% confidence intervals. Fig. 3. The code-switching tendency in balanced dual-language-learning children.
Note. Language proficiencies in the societal and heritage language are simulated at an equal level. 10 L. T. Schächinger Tenés et al.
skills on general code-switching frequency, and differentially for specific code-switching directions and purposes. Using linguistically and psychometrically parallelized language tests allowed to present an initial valid assessment of code-switching tendencies in dual-language-learning children regardless of underlying language abilities.
The influence of dual-language proficiency on children's code-switching behavior In line with Hypothesis 1, we found clear evidence that code-switching represents an expression of linguistic competence. Into both language directions, high language proficiency was associated with more switches into this same language, and low language proficiency was associated with fewer switches. These patterns were not better explained by child-or family-specific characteristics. Generally, our findings are consistent with previous research, but so far, this effect has mainly been described either in broader terms of group-level designs (Montanari et al., 2019;Ribot & Hoff, 2014), or in the case of metric analyses, without including parallelized societal-and heritage-language measure nor differentiating for the direction of switches within the same analysis (Kapantzoglou et al., 2021;Montanari et al., 2019;Smolak et al., 2019;Yow & Patrycia, 2015;Yow et al., 2018).
In line with Yow et al. (2018), our study did not indicate that code-switching in young children primarily constituted a compensatory bridging measure for linguistic gaps driven by low language proficiencies. Despite the large sample, negative language-proficiency effects on code-switching frequencies were not significant. This contradicts prominent theories about compensatory causes of code-switching as the Ivy Hypothesis (Bernardini & Schlyter, 2004) and empirical findings that support compensatory code-switching occurrences (Montanari et al., 2019;Smolak et al., 2019). However, previous studies did not use both language skills simultaneously to predict code-switching frequencies into both directions. Separate analyses may result in interlinked negative and positive effects that cannot be clearly interpreted. In particular, this might be the case, if in some dual-language-learning children the acquisition of a linguistic skilllike vocabularyin both languages is not acquired in parallel but in a context-specific and complementary manner (Hoff & Core, 2013). Moreover, the absence of negative languageproficiency effects in our study was not consistent with the fact that parents explicitly identified compensation as a main reason behind children's code-switching behavior. However, even linguistically-competent children may reach linguistic limits, especially if they are expected to meet higher standards in a conversation that exceed those of less proficient peers (Piasta et al., 2012;Wermelinger, Gampe & Daum, 2017). In this view, code-switching likely serves as a creative bridging strategy for dual-language learners at all proficiency levels, in order to best meet their respective communicative requirements.

Code-switching purposes in relation to linguistic proficiency and age
In contrast to Hypothesis 2, we found no change in code-switching purposes; that is, purpose did not change with an increase in language skills nor age (i.e., as proxy for cognitive maturation). We expected predominantly compensatory and preferential code-switching in less proficient and younger children (Montanari et al., 2019;Smolak et al., 2019) and predominantly pragmatic code-switching in more proficient and older ones (Auer, 1998;Ervin-Tripp & Reyes, 2005;Raichlin et al., 2019). Although parents have reported all three purposes in children's speech, the frequency rankings of the three code-switching purposes were constant across the entire preschool period with compensatory purposes being the most common, followed by preferential code-switching. Pragmatic code-switching occurred the least frequent, even among language-skilled and more mature children. The high intercorrelations of the ratings on codeswitching purposes indicate that frequent compensatory, preferential, and pragmatic code-switching could occur within the same children. Our findings are consistent with Halpin and Melzi's (2021) results that the code-switching purposes remain essentially stable through preschool. The age range in the aforementioned study was comparable to ours (approximately 3 to 5.5 years). It might be that children who grow up in a dual-language-learning environment are metalinguistically sensitized at a particularly early age (Comeau et al., 2007;Goetz, 2003), explaining pragmatic code-switching emerging early in childhood. Moreover, even older dual-language-learning preschoolers might be still too young to have acquired sufficient competencies to widely abandon fluency-related code-switching (Raichlin et al., 2019;Vu et al., 2010). This assumption is reinforced by the finding that even adults seem to code-switch for fluency-related reasons (Rodriguez-Fornells et al., 2012).

Asymmetries in children's code-switching behavior
Hypothesis 3, pertaining to code-switching tendency in duallanguage learners, was addressed in a differentiated manner. Previous findings suggest a general tendency to code-switch into the more prestigious societal language (Montanari et al., 2019;Smolak et al., 2019). However, these studies were conducted either without strictly controlling for the ratio of language skills or without psychometrically and/or linguistically parallelizing the language tests used to assess language balance/dominance. Using the coefficients of our regression models with strictly parallelized language tests to estimate code-switching values for linguistically-balanced and unbalanced children, our estimates indicated no general tendency toward a specific code-switching direction. However, for the strong positive association of societallanguage proficiency with code-switching, our model demonstrated balanced preschoolers with above-average dual-language abilities to code-switch more into the societal language. Accordingly, children with below-average dual-language proficiencies code-switched comparatively more into their heritage language as a result of infrequent switches toward the societal language. In unbalanced children, the expected code-switching asymmetries toward the dominant language were also particularly affected by societal-language skills. The more pronounced the societal-language ability, the stronger the differences in code-switching frequencies in favor of a dominant societal language, and the smaller the frequency difference in favor of a dominant heritage language. This corresponds strongly with the frequently observed phenomenon that many children from linguistic minorities reduce their heritage-language use and increase their societal-language use after a certain degree of socialization within a majority society (Dubiel & Guilfoyle, 2017;Sheng, 2014;Sheng et al., 2011). Children with high societal-language proficiency have access to numerous developmental support structures in the societal culture. These include contact with educators and peers, extracurricular activities, and other experiences Bilingualism: Language and Cognition 11 of public life. These children might experience the expected language-prestige effect (Gutiérrez-Clellen, Simon-Cereijido & Erickson Leone, 2009;Smolak et al., 2019). Instead, children with low societal-language proficiency may prefer to stay in the surroundings of the known family environment which supports their sense of belongingness to their family community (Fina, 2007). Societal-language skills appear to be the primary acculturation-related factor influencing dual-language-learning children's code-switching tendencies. After controlling for differences in societal-language skills, children from both an Italian-or Turkish-language background showed similar code-switching tendencies despite different degrees of probable acculturation problems in the respective minority populations (Froehlich et al., 2022;Makarova, 2014).

Limitations
This study implemented an economic and parsimonious but still informative assessment method of children's code-switching behavior. This approach has shown to be valid for studying children's code-switching (Bosma & Blom, 2019;Ribot & Hoff, 2014) and our reported order of code-switching purposes and also the correlations with the language scores were consistent with the literature. However, parent-based code-switching ratings have restrictions. Usually, parents are able to interpret the motives for children's code-switching well but cannot provide nuanced and precise linguistic assessments (Bail, Morini & Newman, 2015;Girolametto, 1997;Marchman, Martínez, Hurtado, Grüter & Fernald, 2017). Furthermore, parents are only able to validly assess behavior within the family context. Alternatives for questionnaire-based assessment are speech samples of behavioral observations (Bail et al., 2015;Kang & Lust, 2019;Montanari et al., 2019;Smolak et al., 2019;Yow et al., 2018) or naturalistic recordings (Gaskins, Frick, Palola & Endesfelder, 2021) which use direct observations and can be linguistically accurately assessed by experts. However, these methods also come with limitations. The assessment and evaluation processes are time intensive, leading to smaller investigated samples. Moreover, observations in a prevalent single-language setting showed general infrequent code-switching (Montanari et al., 2019). Our generalized linear mixed modeling approach is well-suited to investigate the impact of item-specific factors like different code-switching purposes by means of a small number of items within a carefully balanced design. However, a more comprehensive scale would allow more accurate distinctions between children's code-switching purposes. A mixed-methods design combining ratings of several raters from different contexts with structured observations and interviews could help identify specific patterns in preschoolers' code-switching behavior. Such studies could further integrate linguistic nuances (e.g., switching position within linguistic units -Halpin & Melzi, 2021or grammatical correctness of switches -Deuchar, 2020; Halpin & Melzi, 2021) to enable an objective distinction between compensatory, preferential, and pragmatic code-switching. Our cross-sectional design represents a further limitation, especially for the investigation of developmental changes in preschoolers' code-switching purposes. Longitudinal analyses may provide a clearer picture about such subtle changes. Future crosssectional studies could improve the design and integrate toddlers and/or school-aged children as the present findings assume that changes in code-switching purposes occur earlier and exist for a longer period (Comeau et al., 2007;Halpin & Melzi, 2021;Rodriguez-Fornells et al., 2012).
Moreover, family background variables were included to a limited extent as explanatory variables. This was mainly due to our focus on child-internal mechanisms of code-switching, the complexity of the models, and incomplete data. Additionally, this studylike many othersexamined a sample that is not representative of the totality of minority groups in Central Europe in terms of educational background. For the investigation of influencing family variables a more representative sample would be desirable. Moreover, parental attitudes toward code-switching and their own and familial code-switching practices probably affect children's code-switching (Wu, Cai, Liang & Li, 2021). Families' concrete acculturation strategies and problems might additionally explain code-switching patterns in children (Berry et al., 2006). A study focusing on external factors like acculturation could account better for individual language groups and could emphasize more on language combinations and national backgrounds with balanced sample sizes. Additionally, we did not specify distinct sociolinguistic groups due to the child-internal linguistic focus, the study design, and the analytic procedures. Nevertheless, social experiences of linguistically similar children may vary enormously. Italian-speaking children in Romance environments as French-speaking Switzerland might have qualitatively different acculturation experiences compared to Italian-speaking children in German-speaking environments. Hence, future studies could account for family-context factors (e.g., family-member-dependent language choice, acculturation patterns) and further child-internal factors (e.g., cognitive abilities, context-dependent code-switching) to better understand the origin and development of children's code-switching behavior.
Finally, the assessment of language skills in our study reveals another problematic area within which code-switching studies are situated. Our language tests have been linguistically and psychometrically optimized for generalizability across individual language groups. Idiosyncratic aspects of individual languages, such as specific morphological markers, or culturally accentuated semantic domains (e.g., religious festivals) were not integrated into the language tests or were psychometrically selected out. Since only a few linguistic structures and semantic domains had to be omitted, a substantial limitation of the content validity of our tests is not to be expected. Nevertheless, such individual language specificities could play an important role especially for pragmatic code-switching. Psycholinguistic studies, in the field of phonology with specially selected stimuli, show that overlapping and non-overlapping linguistic structures can lead to crosslinguistic transfer or interference effects (Broersma, Carter, Donnelly & Konopka, 2020). Similarly, pragmatic code-switching might feed on special knowledge of language-specific structures or culture-specific vocabulary used in a situation-specific manner. Future studies could focus on general and specific language skills when assessing language abilities.

Conclusion
To our knowledge, the present study is among the first using a generalized linear mixed modeling to investigate simultaneously potential positive and negative language-ability effects on the frequency with which preschoolers code-switch into both languages. Code-switching mainly expresses linguistic strengths but not linguistic weaknesses consistently across the preschool years. Still, our results attest preferential and pragmatic but also compensatory purposes within the same individual child. Purely deficitor strength-oriented inferences based on code-switching behavior cannot be justified on the basis of our findings. Our study also reveals a certain code-switching asymmetry. Children with aboveaverage societal-language skills show a particular strong switching tendency toward the societal language, while children with below-average societal-language abilities switch particularly rarely into the societal language. Such findings, and also the innovative design, may stimulate future research to further clarify how familial and societal environments affect code-switching. For parents and childcare professionals, these findings might enable them to better understand underlying mechanisms of children's code-switching even if they do not necessarily facilitate diagnosis and intervention. The results characterize code-switching as a particularly illustrative example of preschoolers' dual-language development; communicative strategies are already apparent and flexibly applied. Still, linguistic and syntactic gaps must be constantly bridged due to constant development and adaption to emerging contextual expectations.
Mplus 8 (Muthén & Muthén, 2017). Tests for measurement invariance of the language scales were conducted to identify differences in construct validity between the different language groups of our study. With measurementinvariant scales children can be compared quantitatively in terms of their societal-or heritage-language skills despite different language backgrounds.
We tested for two levels of measurement invariance, metric and scalar, in a two-parameter logistic model. For an item to be metrically invariant across different groups, there must be no significant group differences in its factor loading. If this is the case, the item differentiates similarly well between children with higher and lower language abilities in all groups. In studies with linguistically different groups, a difference in factor loadings can occur, for example, if there is a translation error in the test material. In Figure A2.1., the dotted bottom line shows that this would become visible as an unexpectedly flat item characteristic curve. For an item to be additionally scalar invariant, it must also have similar response thresholds across all groups, which is the proficiency level at which one would assume that the probability of solving an item is just 50%, which is the same as the probability of not solving it. In crosslinguistic studies sometimes scalar invariance is difficult to establish, because children of certain groups can approach an item with an advance acquired through culture-specific prior knowledge (e.g., an item in which Christmas plays a role). In Figure A2.1. you can see how such a starting advantage would become visible by the parallelly shifted, dotted upper line.
To obtain precise measurement parameters of the societal-language items, not only dual-language learners with Italian (n = 72) and Turkish (n = 74) as a heritage language were included for the estimations, but also the single-language-learning sample containing speakers of German (n = 161) and French (n = 67). Hence, societal-language items were tested across the entire sample of 374 single-and dual-language learners. Invariance of heritage-language item parameters was tested across 146 dual-languagelearning children (n Italian = 72; n Turkish = 74). For testing the assumptions of metric and scalar measurement invariance, factor loadings and thresholds were first freely estimated for each group. Subsequently, the parameters were fixed to equality between groups within the societal and within the heritage language (Van de Schoot, Lugtig & Hox, 2012). The invariance assessment was based on the AIC and BIC. Items for which fixing the parameters on equality across groups led to a deterioration of the model fit were not used for the factor score estimation. For the societal-language tests, factor score estimation was based on 28 of 32 receptive vocabulary items, 18 of 32 productive vocabulary items, and all 32 sentence comprehension items. For the heritage-language scores all 32 receptive vocabulary items, 29 of 32 productive vocabulary items and all 32 sentence comprehension items were used for estimation.
For the psychometrically parallelized societal-and heritage-language tests necessary for Hypothesis 3, an even more rigorous procedure of measurement invariance testing was conducted. To carry out the necessary analyses, it was not enough that the linguistic content of the societal-and the heritage-language tests be comparable. In addition, it had to be ensured  (Segerer et al., 2021) Note. The parameters of the societal-language item hoof match the parameters of the respective heritage-language twin item fin, which results in a psychometrically parallelized language test item. Fig. A3.1. The code-switching tendency controlling for dual-language proficiency in unbalanced dual-language-learning children being dominant in the heritage language Note. Heritage-language dominance simulated at a discrepancy of one standard deviation from the societal language.
that the societal-and heritage-language scores were also psychometrically comparable. This means that the variance of the scores in the heritage and in the societal language results in equal parts from linguistically comparable items. If the scalar invariance assumption of the same thresholds is not rejected, proficiency levels can be directly compared with each other; that is, one can determine whether a child has higher competency in the societal or the heritage language. For such analyses, however, the measurement parameters of the societal-language items had to match the parameters of the corresponding linguistic twins in the heritage-language tests. If the assumption of invariant parameters (factor loadings and thresholds) was not rejected, the item pair was kept; otherwise, the item pair was not considered for the estimation of parallelized societal-and heritagelanguage scores. Figure A2.2. illustrates how these item twins would have to prove psychometrical equivalence to be used for the parallelized societal and heritage language factor score estimation. This extremely strict criterion was reached for 12 of 32 receptive vocabulary items, 6 of 32 productive vocabulary items, and 13 of 32 sentence comprehension items. Despite the somewhat high number of excluded items, the resulting factor scores showed remarkable reliability estimates (.73-.87;Segerer et al., 2021) and a quite substantial variance.
Appendix 3. Code-switching direction tendencies in unbalanced dual-language learners For our hypothesis 3, we aimed at investigating whether dual-language learners show asymmetries in their code-switching direction with a tendency toward the more prestigious societal language. While we addressed this research question by analyzing code-switching preferences in balanced dual-languagelearning children, we sought here, to concentrate on unbalanced dual-language learners. We investigated whether for linguistically-unbalanced children a switching tendency toward the dominant language would be lower in children with a heritage-language dominance in comparison to children with a societallanguage dominance. For this purposesimilar to the procedure for balanced dual-language learnersthe heritage-and societal-language scores were centered one standard deviation apart. Once the language scores were centered so that the heritage language was stronger and once so that the societal language was dominant. With these centered language scores the same analytical approach was followed as for balanced dual-language learners. The resulting effects for code-switching direction in unbalanced dual-language learners are illustrated for children being dominant in the heritage language ( Figure A3.1.) as well as for children being dominant in the societal language ( Figure A3.2.). Fig. A3.2. The code-switching tendency controlling for dual-language proficiency in unbalanced dual-language-learning children being dominant in the societal language Note. Societal-language dominance simulated at a discrepancy of one standard deviation from the heritage language.