Time-course variation of statistics embedded in music: Corpus study on implicit learning and knowledge

Learning and knowledge of transitional probability in sequences like music, called statistical learning and knowledge, are considered implicit processes that occur without intention to learn and awareness of what one knows. This implicit statistical knowledge can be alternatively expressed via abstract medium such as musical melody, which suggests this knowledge is reflected in melodies written by a composer. This study investigates how statistics in music vary over a composer’s lifetime. Transitional probabilities of highest-pitch sequences in Ludwig van Beethoven’s Piano Sonata were calculated based on different hierarchical Markov models. Each interval pattern was ordered based on the sonata opus number. The transitional probabilities of sequential patterns that are musical universal in music gradually decreased, suggesting that time-course variations of statistics in music reflect time-course variations of a composer’s statistical knowledge. This study sheds new light on novel methodologies that may be able to evaluate the time-course variation of composer’s implicit knowledge using musical scores.


Implicit learning and statistical learning
Implicit learning and knowledge is a ubiquitous phenomenon that occurs without the intention to learn and awareness of what we know [1,2]. A number of studies have investigated this form of learning using several paradigms [3,4,5,6]. In a series of psychological and neurological studies, the learning and knowledge of transitional probability in sequential information such as music and language-called statistical learning and statistical knowledge-have been considered implicit processes that could be performed domain-generally in both music and language regardless of sensory modalities. Thus, the terms implicit learning and statistical learning have been used interchangeably and are regarded as the same phenomenon [6], although some researchers stated statistical knowledge and implicit knowledge may exactly not be same thing. In daily life, using the framework of statistical learning, we benefit immensely from artificial intelligence such as machine learning that gives computers learning ability similar to humans PLOS ONE | https://doi.org/10.1371/journal.pone.0196493 May 9, 2018 1 / 18 a1111111111 a1111111111 a1111111111 a1111111111 a1111111111 [7,8]. By calculating statistics on what we did in the past, computers can predict what we will do next, and they also give the best information, even when we are unaware of what we statistically want. In several fields of study on machine learning and natural language and music processing [9][10][11][12][13][14][15][16][17][18], the Markov chain has often been used as a model of the artificial grammar of language and music. The Markov chain, which was first reported by Markov [19], is a mathematical system in which the probability of the forthcoming state is statistically defined only by the latest state. The use of the Markov chains embedded in tone sequences allows us to verify the statistical structure of music [12][13][14][15][16][17][18] and statistical learning and knowledge in humans [20][21][22][23].
There are a number of evidences suggesting that statistical knowledge is implicit, although some researchers report that knowledge gained from statistical learning may result in both implicit and explicit knowledge [24]. Due to the implicitness of statistical learning in humans, however, we cannot specify the learned statistical knowledge, even when the learning effects are neurophysiologically unveiled [21,25,26] based on the framework of predictive coding [27]. In other words, implicit statistical knowledge can be acquired in our brains even though it does not reach the level of explicit awareness of what we learned. Despite the fact that humans are unaware of the learned statistical knowledge of auditory sequences, they can, however, identify that sequences containing high transitional probabilities sound familiar [20,21]. That is to say, although statistical knowledge itself may be implicit to a certain degree and does not reach the level of explicit awareness, it can be alternatively expressed via an abstract medium such as a musical melody [12][13][14][15][16][17][18].

Characteristics of music: Implicit and explicit aspects
Music has numerous domain-specific structures (e.g., isochronic metrical grids, tonal pitch spaces, hierarchical tension, and attraction contours based on the structure of a melody and chord progression), and cannot be fully explained solely by the domain-general statistics of transitional probabilities [28,29]. Thus, the general hypothesis is that music is learned by both statistical learning and music-specific learning [30,31]. In general, musical composers explicitly learn music-specific knowledge such as musical grammar, and intentionally follow these frameworks when composing music. Musical rules and how they should be followed vary over time and among traditions, genres, and composers themselves. Therefore, the characteristics of music can be extracted based on music-specific structures, such as the harmony, tonalities, relative pitches, and musical intervals in the musical scores [32][33][34][35][36][37][38][39][40][41][42]. To the best of our knowledge, however, few studies have verified whether the characteristics of music can be extracted based on the statistical structure in the musical scores. Furthermore, no study has investigated how the characteristics of the statistical structure in music varies over a composer's lifetime.
transitional probability based on Markov chain) models may represent the ability of general humans and musical experts, respectively. Thus, the time-course variations of statistical structures in music may represent the time-course variations of a professional composer's statistical knowledge. Nevertheless, there are few studies that investigate time-course variations of a composer's statistical knowledge by analyzing musical score. To understand mental representation of statistical knowledge in music, it is important to examine the relationships among statistical structures in music, music composition, and implicit knowledge.

Musicological aspects on the statistics of Ludwig van Beethoven's Piano Sonata
In the transition from eighteenth-century musical classicism to nineteenth-century romanticism in Western music, Ludwig van Beethoven was a German composer and pianist (1770-1882) who was highly influential to other composers. In musicological study, Beethoven's compositional career is divided into early (around 1802), middle (around 1802 to 1814), and late periods (from about 1814) [51,52]. Compared to his works in the early period, which were strongly influenced by his predecessors in classicism, such as Wolfgang Amadeus Mozart (1756-1792) and Franz Joseph Haydn (1732-1809), his works in the late period, when he was already troubled by deafness and irritability brought on by chronic abdominal pain, were considered to show his personal expression and intellectual depth [51,52]. It is also believed that Beethoven always explored new directions and gradually expanded his scope of music over his lifetime [51,52]. Musicological researchers suggest that Beethoven's music expressed his vision of life [53,54]. Sullivan [53] claimed that Beethoven's vision was the product of his character and experience. Thus, his psychological variations on thinking and experience may form the character of his music [55]. The present study hypothesized that the time-course variations of statistical structures in Beethoven's music over his lifetime might reflect the time-course variations of his statistical knowledge. As such, it would be very interesting to examine if the psychological variations in which Beethoven explored new directions and gradually expanded his scope of music over his lifetime [51,52] were reflected in the statistics of his music. Based on the hypothesis, the present study investigated how statistical structures in music vary over a composer's lifetime.

Study purpose
The present study aimed to investigate how statistical structures in music vary over a composer's lifetime. The transitional probabilities of the sequences containing the highest pitches in Ludwig van Beethoven's Piano Sonata with all of the movements (Piano Sonata No.1 in F minor, Op.2-1 to No.32 in C minor, Op.111) were calculated based on seven different hierarchical Markov stochastic models (i.e., first-to seven-order Markov chains). Although melody is sometimes not highest pitches e.g. bass melodies), the present study only analyzed the highest pitch because the definition of melody in each title of music is still controversial in musicological study, different melodies could concurrently appear in some titles of music, and melody is often played in highest pitches. To understand how the transitional probability of more general sequences that is consistently used by one composer, the present study just targeted the interval pattern that appear in all 32 sonatas. The time-course variations of the transitional probabilities in each interval pattern that appear in all 32 sonatas were examined. It was hypothesized that there may be two types of time-course variations: transitional probabilities that gradually decrease and those that gradually increase, consistent with the sonata opus number. If so, these findings suggest that the statistical knowledge of music gradually shift over a composer's lifetime.

Methods
The Ludwig van Beethoven's Piano Sonata and all of its movements (No.1 in F minor, Op.2-1 to No.32 in C minor, Op.111, composed 1795-1822) was used in the present study (Beethoven, Piano Sonata No.1 to No.32, Breitkopf & Härtel, Leiptig). Using a scorewriter (Finale version 25, MI Seven Japan, Inc.), electronic scoring data of the sequences of highest pitch were extracted from the XML files. The highest pitches were chosen based on the following definitions: the highest pitches that can be played at a given point in time, the pitches with slurs can be counted as one, and the grace notes were excluded (S1 Table). Using all the sequences of highest pitches in a movement of a Sonata, the transitional probabilities of the sequences of highest pitches were calculated as a statistic based on Markov chains. The weighted averages of transitional probabilities of all the movements in a Piano Sonata were calculated. The probability of a forthcoming tone was statistically defined by the last tone to seven successive tones, respectively (i.e., first-to seven-order Markov chains).
norder Markov model is based on the conditional probability of an element e i+1 , given the preceding n elements: Then, for each type of pitch transition, all pitches were numbered so that the first pitch was 0 in each transition, and an increase or decrease in a semitone was 1 and -1 based on the first pitch, respectively. The representative examples were shown in Fig 1. This revealed interval patterns but not pitch pattern [43,56]. This procedure was employed to eliminate the effects of the change of key on interval patterns. The interpretation of the change of key depends on musicians, and it is difficult to define in an objective manner. Thus, the results in the present study may represent a variation of statistics associated with relative pitch rather than absolute pitch.
Each interval pattern was ordered based on the Sonata opus numbers (i.e., Piano Sonata No.1 in F minor, Op.2-1 to No.32 in C minor, Op.111). Using the interval patterns that appear in all 32 sonatas, the time-course variations of the transitional probabilities were analyzed by multiple regression analyses using the stepwise method. Statistical significance levels were set at p = 0.05 for all analyses. The criteria of the variance inflation factor (VIF) and condition index (CI) were set at VIF < 2 and CI < 20 to confirm that there was no multi collinearity [57]. Based on the stepwise method, the regression model that showed greatest numbers of interval patterns were adopted. Next, all of the highest-order transitional probabilities that showed statistical significance were calculated in the first (No.1) and last (No.32) sonatas. Furthermore, the representative phrases that transitioned with the highest probability in the first and last sonatas were decoded as music scores.

Results
Twenty-two interval patterns with two tones that appear in all 32 sonatas were detected (  (Table 3). Using these interval patterns, a multiple linear regression based on the stepwise method was carried out to predict the numbers of music based on the transitional probabilities of the 37 interval patterns in the second-order Markov chain. A significant regression equation was found (F(4,27) = 10.10, p = 0.0001), with an adjusted R 2 of 0.54 (Table 4). The predicted sonata opus number is equal to 32.  (Table 5). Using these interval patterns, a multiple linear regression based on the stepwise method was carried out to predict the sonata opus numbers based on the transitional probabilities of the 12 interval patterns in the third-order Markov chain. A significant regression equation was found (F(2,29) = 9.25, p = 0.001), with an adjusted R 2 of 0.35 ( Table  6). The predicted sonata opus number is equal to 39.12-28.81 (transition of [0,2,0,-1]) -24.82 Table 1 (Table 7). Using these interval patterns, a multiple linear regression based on the stepwise method was carried out to predict the sonata opus numbers based on the transitional probabilities of the three interval patterns in the fourthorder Markov chain. A significant regression equation was found (F(1,30) = 6.65, p = 0.015), with an adjusted R 2 of 0.15 (Table 8). The predicted sonata opus number is equal to 27.13-19.27 (transition of [0,-2,-3,-5,-7]). The transitional probabilities gradually decreased consistently with the ascending order of the sonata opus numbers (p = 0.015). The transitional probabilities were significant predictors of the sonata opus numbers. To understand how the transitional probabilities of [0,-2,-3,-5,-7] were shifted in more detail, the transition matrices based on the fourth-order Markov chain of P(X|0, -2, -3, -5) in the first (No.1) and last (No.32) sonatas are shown in Table 9. Furthermore, the representative phrases that transitioned with the highest probability in the first and last sonata were decoded as music scores (Fig 1).
One interval pattern with six tones that appeared in all 32 sonatas was detected (0,-2,-4,-5,-7,-9) (Table 10). Using these interval patterns, a multiple linear regression based on the stepwise method was carried out to predict the sonata opus numbers based on the transitional probabilities of the interval patterns in the fifth-order Markov chain. No significant regression equation was detected, however. No sixth-or higher-order interval patterns appeared in all 32 sonatas.     Time-course variation of statistics embedded in music   Table 9. Transition matrices based on the fourth-order Markov chain (P(X|0, -2, -3, -5)). Time-course variation of statistics embedded in music 4. Discussion

Psychological relationships between variation of statistical structure in music and implicit knowledge
A tone with a higher transitional probability of sequences in a musical score may be one that a composer is more likely to choose compared to other tones with lower transitional probability [20][21][22][23][58][59][60]. Thus, the transitional probability matrix calculated from music may represent the characteristics of a composer's statistical knowledge by which a forthcoming tone is implicitly defined. The present study aimed to investigate how the statistical structures in music vary over a composer's lifetime. I hypothesized that there might be two types of time-course variations: transitional probabilities that gradually decrease and those that gradually increase, consistent with the order of the sonata opus number. If so, these findings suggest that statistical knowledge of music, which are generally considered implicit phenomenon, gradually shifts over a composer's lifetime.  Table 11. The transition matrices of P(X|0, -2, -3, -5) in the first (No.1) and last sonatas (No.32) are shown in Table 10. The representative transition of [0,-2,-3,-5,-7] in No.1 was decoded as musical scores in Fig 1A. In these familiar sequences, decreasing transitional probabilities were detected more frequently than increasing Table 11. The examples of transitions in which transitional probabilities were gradually increased and decreased. transitional probabilities. This finding suggests that, in the later period of his life, Beethoven composed statistically novel music in which predictable and familiar transitions did not appear compared to the earlier periods. The sequences with 5 tones based on fourth-order transitional probabilities were the longest in the transitions that showed significance, suggesting that the time-course variation of statistical structure that could implicitly reflect strategy of music composition may depend on until fourth-order transitional probabilities. According to the previous neurophysiological study on statistical learning, fourth-order transitional probabilities in auditory sequences modulate prediction in human's brain [61]. Furthermore, they suggested that, higher-order transitional probabilities could modulate learner's prediction when they learn more difficult statistical structure. These findings may suggest that the findings of the present study are in part related to prediction and expectation in the composer, although this study could not detect difference among the orders of transitional probability. On the other hand, the only interval patterns that appear in all 32 sonatas were used to verify the variation of transitional probabilities of the familiar sequences in the 32 sonatas. In total, there are more than several billion kinds of interval patterns in music. Thus, it is difficult to define the statistical significance when we target all of the interval patterns. Future study will need to investigate interval patterns that do not appear in some sonatas.

Variation Transition Number of notes Examples in C major
To understand how the highest-order (i.e., fourth-order) transitional probabilities of [0,-2,-3,-5,-7] shifted in more detail, the transition matrices based on the fourth-order Markov chain of P(X|0, -2, -3, -5) in the first (No.1) and last (No.32) sonatas were investigated (Table 10). In the transition matrices of Sonata No.1 (Table 10), the distribution of transitional probabilities was biased: the transitional probability of [0,-2,-3,-5,-7] was markedly higher than that of any other transitional probabilities. In contrast, in the transition matrices of Sonata No.32 (Table 10), the transitional probabilities were equally distributed compared to the transition matrices of Sonata No.1: there was no obvious highest transitional probability. The representative phrases with the highest transitional probability in Sonatas No.1 and No.32 were decoded as musical scores in Fig  1A and 1B. These findings are consistent with the hypothesis that, in the last sonata, Beethoven tried several composition methods in which he avoided familiar interval patterns. The previous studies indicated that statistical learning contributes to many types of mental representation in music: the comprehension and production of music [62], intuitive decision-making [63,64] and creativity involved in musical composition [15]. The several studies also suggest that, compared to language [65], musical representation including tonality is mainly formed by a tacit knowledge [66][67][68][69][70][71][72]. Furthermore, the neurophysiological studies indicates that the distribution of pitch frequency that mainly forms musical melody, rather than other acoustic features such as formant frequencies that play an important role in forming speech sounds instead of melody, facilitate auditory statistical learning in human's brain [22]. Thus, it is widely accepted that statistical knowledge is tied to musical expression such as composition, playing, and creativity [12][13][14][15][16][17], even if learners cannot realize the acquired knowledge due to implicitness of statistical learning [21]. Given these previous findings, the results of the present study may suggest that the timecourse variations of statistical structures in music represent the time-course variations of a composer's statistical knowledge.
The previous studies demonstrated that the transitional probabilities of relative-pitch patterns could be learned [21,22,73]. Based on these findings, this study analyzed pitch-interval patterns but not absolute-pitch pattern like the methodologies of the previous studies [43,56] in order to eliminate the effects of the change of key on interval patterns. In other words, the present study verifies statistical distribution of relative-but not absolute-pitch structures.

Musicological relationships between Beethoven's lifetime and the statistical variations of music
The numbers of Beethoven's Piano Sonata indicate the order in which the music was published, not when it was composed. Although most of the numbers are consistent with the order in which the music was composed, Piano Sonata No. 19 in G minor and Piano Sonata No. 20 in G major, which were published around 1805, are considered to have been composed a decade earlier, between 1795 and 1798 [74,75]. This means that Piano Sonata No. 19 and No.20 may have been written around the time that Beethoven composed Piano Sonata No.3 and No.4. The specific time of composition remains controversial. Therefore, in the present study, the time courses in which the music was published are used, as they are clearer than the time courses in which the music was composed. The present study revealed the time-course variations of statistical structures in Beethoven's music over his lifetime. In other words, the statistically novel music was composed during Beethoven's significant life events in late periods when he was already troubled by deafness and irritability brought on by chronic abdominal pain and were considered to show his personal expression and intellectual depth [51,52]. According to the previous studies, statistical learning could modulate strategies of musical composition, and the musical training and experience is associated with cognitive model of probabilistic structure in music involved in statistical learning [43,[12][13][14][15][16][17][18]. The neurophysiological studies also demonstrated that musical training modulates the abilities of statistical learning [76,77,78]. These previous findings may suggest that musical experience allows a composer to change the strategies of musical composition based on the acquired statistical knowledge over his/her lifetime. The results of time-course variation of statistical structure in the present study may imply that, in later compositional periods, because Beethoven experienced a lot of composition strategies and explored new directions, he might compose statistically novel music in which predictable transitions did not appear compared to that of earlier periods. According to the previous studies, corpus analyses can detect the historical characteristics of music and in part distinguish them based on the era (e.g., [37,40,79]), suggesting that variation of statistical structure can be detected over long periods of time. The present corpus study also detected the variation of characteristics within a composer in his/her lifetime. It is of note that the present study did not directly demonstrate that the implicit statistical knowledge of music varied, as only the statistics of musical scores were analyzed. This suggests that there are other possible explanations for the results in the present study. For instance, it might be part of his plan to compose the sonatas from familiar to increasingly unfamiliar based on the statistical structure of music. It cannot be excluded the possibility that the findings in the present study do not necessarily reflect that Beethoven's statistical knowledge changed. The human's ability to generate random sequences of numbers [80] has been associated with creativity in human [81]. In addition, to understand variation of transitional probability of more general phrase that is consistently used by Beethoven, the present study only analyzed the sequences that appeared in all pieces of music. One of the reasons is that the phrases that do not appear in all sonatas and showed transitional probability of 0% in some pieces of music is difficult to define composer's knowledge. Compared with these phrases, the consistently appeared phrases may depend on his knowledge. However, there may be another specific variation in phrases that showed transitional probability of 0% in some pieces of music. Future study should investigate the effects of statistical learning and knowledge of all types of phrase on music compositions. The present study shed new light on novel methodologies that may be able to evaluate the time-course variation of composer's implicit knowledge using musical scores.
Supporting information S1 Table. The coded sequence in each piece of music. (XLSX)