Does online investor sentiment explain analyst recommendation changes? Evidence from an emerging market Analysts and textual sentiment

Purpose – Theauthorsexaminehowfinancialanalystsrespondtoonlineinvestorsentimentwhenupdating recommendations for specific stocks in South Africa. The aim is to establish whether online sentiment contains significant information that can influence analyst recommendations. The authors follow up the above by examining when online investor sentiment is most associated with analyst recommendation changes. Design/methodology/approach – For online investor sentiment proxies, the authors make use of the social media sentiment and news media sentiment scores provided by Bloomberg Inc. The sample size includes all companies listed on the Johannesburg Stock Exchange All Share Index. The study uses traditional ordinary least squares to examine the relation at the mean and quantile regression to identify the scope of the relationship across the distribution of the dependent variable. Findings – The authors find evidence that pre-event news sentiment significantly influences analyst recommendation changes while no significant relationship is found with the Twitter sentiment. Further analysisshowsthatnewssentimentismoreinfluentialwhentherecommendationchangesaremoderate(inthemiddleoftheconditionaldistributionoftherecommendationchanges). Originality/value – The studyis the one ofthe firsttoexamine the associationbetweenonline sentimentand analyst recommendation changes in an emerging market using high frequency data. The authors also make a direct comparison between social media sentiment and news media sentiment, some of the most used contemporary investor sentiment proxies.


Introduction
Financial analysts are an important ingredient of the stock market ecosystem as their services often alleviate information asymmetries among stock market participants, ultimately leading to the narrowing of the gap between market prices and fundamental values of financial assets. Corredor et al. (2013), however, note that these financial analysts are often prone to the optimistic bias which frequently clouds their objectivity. Empirical studies have given different reasons for this optimistic bias by financial analysts, with one strand of literature assuming that investors are completely rational and can therefore not be affected by irrational factors in the market. Some studies along this strand of literature have attributed the optimistic bias of financial analysts to conflict of interest (Rountree, 2009), informational advantages (Bartholdy and Feng, 2013) and market conditions (Chang and Choi, 2017). Another strand of literature argues that the optimistic bias of analysts is driven by the irrationality or "incomplete rationality" of analysts (Wu et al., 2018). This line of scholarly research links the bias in analyst recommendations to investor sentiment, for example.
Various studies have since been done on the role played by investor sentiment on the reports and recommendations generated by financial analysts. The majority of the studies that have examined the effect of investor sentiment on analyst consensus changes have used composite proxies for investor sentiment. In the digital age where stock opinions and news largely flow from online platforms, it is essential to establish whether online investor sentiment can influence the expert opinions of financial analysts. Also, research shows that not all the sentiment measures are the same as argued by Bu (2021) who compares direct and indirect proxies for investor sentiment and finds a relatively low correlation between them. It is therefore of paramount importance to examine the effect of investor sentiment on analyst recommendations using a different set of sentiment proxies. We choose the South African market for various reasons. Firstly, most studies along this line have been done on emerging and developed stock markets. The JSE is a hybrid stock market with characteristics of both developed and emerging markets as explained by Seetharam (2022) who asserts that the JSE is sometimes classified as both emerging and developed. The JSE is, for example, dominated by institutional investors [1] (Nyakurukwa and Seetharam, 2022) like developed markets (contrary to other emerging markets like China which are dominated by retail investors) but is less liquid compared to developed markets [2]. This offers interesting avenues for research as institutional investors are known to be less prone to investor sentiment compared to retail investors, while at the same time, less liquid stocks are known to be driven by sentiment more than liquid stocks. An analysis using the JSE, therefore, provides new insights into such a market. Secondly, though South Africa has seen an increase in retail investors in the past few years, it remains dominated by institutional investors. Traditionally, retail investors are the ones who have often been reported as prone to investor sentiment. However, in recent studies, evidence has also been provided that institutional investors are also prone to behavioural biases as well as being sentiment traders (Wang and Duxbury, 2021). This study, therefore, provides a platform to examine these findings from recent studies and put them in a different context.
Given that the optimistic bias of financial analysts has been documented in South Africa (L€ otter and Smit, 2018), this study seeks to examine whether this bias could be traced to online investor sentiment. This paper aims to empirically examine two issues in a South African context. The first issue is to establish if the online investor sentiment (from Twitter and online news articles) can influence analyst recommendation changes. We compare two of some of the most used sentiment proxies in the digital age; news sentiment and Twitter sentiment. If a statistically significant relationship is established, we go further to examine this relationship across the distribution of the analyst recommendation changes. The purpose is to establish if the relationship between online investor sentiment and analyst recommendation changes is uniform across the distribution of analyst recommendation changes or heterogeneous.
We have particularly included a social media proxy as studies have shown that it plays a disciplining role in financial markets (Hibbert et al., 2022). For example, it is documented that analysts tend to issue optimistic earnings forecasts because of conflicts of interest as well as economic incentives (Michaely and Womack, 1999). However, the proliferation of social media has amplified competition among information producers which may lead to analysts issuing less biased forecasts (Hibbert et al., 2022).
Our article contributes to the increasing related body of knowledge in several ways. Firstly, we find that pre-event Twitter sentiment does not influence analyst recommendation changes. Rather, it is the sentiment from online news articles that significantly influences analyst recommendation changes. Using quantile regression, we find that news sentiment influences analyst recommendation changes more in the middle of the analyst recommendation change distribution. This means that moderate changes in analyst recommendations can be explained more by sentiment from news than large upgrades or downgrades. Huge analyst upgrades and downgrades are associated less with news sentiment showing that news sentiment is less important to analysts when they make large upgrades and downgrades of stocks. Twitter sentiment is not significantly related to analyst change recommendations across the conditional distribution of analyst recommendation changes. Rather than relying solely on analyst recommendations, investors need to independently check whether the recommendations are driven by news sentiment, especially when the recommendation changes are moderate.
The study proceeds as follows; Section 2 reviews related literature, Section 3 outlines the methodology used in the study; Section 4 presents the results and the discussion thereof while Section 5 concludes.

Literature review
The importance of analyst recommendations in reducing information asymmetry in the stock market can be inferred from Conrad et al. (2006) who equated analyst recommendations to capital budgeting decisions. Womack (1996, p. 164) asserts that stock recommendations are analogous to a financial analyst stating that "I have analysed publicly available information, and the current stock price is not right". This suggests that if the market price is sufficiently below or above the "true value" indicated by the model used by the analyst, the stock is given either a buy or a sell recommendation respectively. Though in principle, financial analysts want to be as accurate as possible to satisfy investors, they are sometimes self-driven, exhibiting a desire to either retain or gain investment banking business from the underlying companies being rated. This often leads to the upward bias in the analyst recommendations documented by Stickel (1995).
Various studies have been done to establish the causes of analyst optimistic bias. Corredor et al. (2013) ascribe the causes of analyst optimistic bias to three aspects namely; economic incentives for the analysts, the cognitive bias of the analysts as well as the negative skewness in earnings. The explanation of analyst optimism related to incentives for analysts is mainly embedded in investment banking businesses. The commissions for the analyst brokerage services entice analysts to make upward biased recommendations as well as earnings forecasts (Lin and McNichols, 1998). Irvine (2004) reports that when analysts generate optimistic recommendations, this generates high trading commissions through the brokerage firms of the analysts. Regarding the cognitive bias of the analysts, analysts are prone to overreactions to the good news about the prospects of a company as well as to overvaluations due to the prevalence of speculators (Corredor et al., 2013). Analysts can also show signs of overconfidence in the accuracy of their own private information (Friesen and Weller, 2006). According to Corredor et al. (2013), the connection between cognitive bias and optimism of financial analysts provides investor sentiment as a potential explanatory factor for the optimism of recommendations offered by the analysts. The connection between cognitive bias, analyst optimism and investor sentiment has resulted in various empirical studies striving to examine the effect of investor sentiment on analyst recommendations. Hribar and McInnis (2011) utilise correlation analysis to establish the link between investor sentiment and recommendations and find no significant connection between the two. Corredor et al. (2013) use four key European markets namely Germany, France, Spain, and the United Kingdom to establish whether investor sentiment influences analyst recommendations and report that in all the countries, investor sentiment influences analyst recommendations, especially in small, hard to value stocks. Gu and Kurov (2020) report that pre-event Twitter sentiment positively influences analyst recommendation changes. Hibbert et al. (2022) show that Twitter information reduces forecast optimism and improves forecast accuracy of sellside equity analysts and that negative Twitter information is more influential, and this effect is distinct from the impact of news. The majority of the studies on the relationship between analyst recommendation changes and textual sentiment have been done in developed markets. It is therefore essential to determine whether this relationship holds in an emerging market like South Africa, which has different properties compared to developed markets.
Models based on the Ordinary Least Squares (OLS) assume that the effect of one variable on the other variable is uniform across the distribution by giving estimates at the mean. To see the effect of online investor sentiment across the distribution of the analyst recommendation changes, various empirical studies have adopted methods that show the relationships between variables at points other than the mean (Lin et al., 2019). One particular method that has been adopted by researchers is quantile regression which shows the association between variables across the distribution of the dependent variable. The Prospect Theory suggests that the expected utility theorem does not adequately capture human behaviour in the face of gains or losses (Kahneman and Tversky, 1979). According to Prospect Theory, individual investors are more reactive to significant pain from a loss compared to excitement from a gain of comparable magnitude (Kahneman and Tversky, 1979). This proposition asserts that the behaviour of investors varies significantly, depending upon the state of the capital markets and whether they are characterised by periods of anxiety and fear or by prosperity and tranquillity. Since analysts can also be invested in the companies they analyse (conflict of interest), they are also likely to react differently depending on the strength of the sentiment from news and/or tweets. There is therefore a need to explore whether analyst recommendation changes are homogeneously associated with investor sentiment or the association is heterogeneous.

Data
All the data used in this study were gathered from Bloomberg Inc. The study uses all the firms listed on the FTSE/JSE All Share Index (JALSH). The JALSH represents 99% of the full market capital value of all ordinary securities listed on the main board of the Johannesburg Stock Exchange, subject to minimum free float and liquidity criteria. Bloomberg Inc. started incorporating social media sentiment data on its platforms on 1 January 2015. However, for this study, the sample is restricted to the period 1 January 2016 to 30 July 2021 to alleviate the significant amount of missing values in 2015 [3]. Bloomberg Inc. only provides sentiment data for currently listed companies. Thus, companies delisted during the sample period are not included in the analysis. The survivorship bias because of the aforementioned exclusion of certain companies is therefore a potential caveat of this paper. Also excluded are all companies without any data on online investor sentiment and/or analyst recommendations. Ultimately, the final database upon which this study was based contains firm-level unbalanced data for 140 companies with 151,354 firm-day observations.
In the studies done to establish whether investor sentiment influences analyst recommendations, various proxies for investor sentiment have been used. Corredor et al. (2013) use the composite index constructed following Baker and Wurgler (2006) consisting of the following sentiment indicators; closed-end fund discounts, stock turnover, number of initial public offerings, the equity share in new issues as well as the dividend premium. Kim et al. (2021) use the Huang et al. (2015) approach which is reputed to be more effective than the Baker and Wurgler (2006) approach as it filters out the error components of the latter index. Gu and Kurov (2020) use sentiment from tweets collected from the Twitter platform. Most of the studies done in this domain have used composite indexes constructed from various variables as proxies for investor sentiment. Gu and Kurov (2020) use a direct measurement of firm-level textual sentiment from Twitter as a proxy for investor sentiment. We propose to go further by incorporating news sentiment to see which is more influential for financial analysts in South Africa; news sentiment or social media sentiment. We also expand Gu and Kurov (2020) by exploring the relationship across the distribution of online investor sentiment.
3.2 Variables 3.2.1 Analyst recommendations. The analyst recommendation consensus scores for the sampled companies are obtained from Bloomberg. Bloomberg Inc. reports analyst consensus recommendations which have a minimum value of 1 (strong sell) to 5 (strong buy). The rating is calculated by converting each of the analysts' current recommendations into a number from 1 to 5 and taking the average. While some studies have used analyst recommendation levels in examining the effect of analyst recommendations on stock market variables, Jegadeesh et al. (2004), state that recommendation changes are more informative than recommendation levels. We calculate analyst recommendation change as the percentage change in the recommendation score from time tÀ1 to time t. Using this definition, a positive recommendation change is referred to as an "upgrade", a negative change is a "downgrade" while "no change" refers to the reinstatement of a previous recommendation score.
3.2.2 Online investor sentiment. In this study, we use two proxies for online investor sentiment, namely; Twitter sentiment and news sentiment. The process of calculating the news/Twitter sentiment used by Bloomberg Inc. starts with manually analysing large datasets of tweets and news articles using human experts. Labels are then assigned to each news article/tweet and categorised into positive, negative and neutral labels using the following question; if an investor having a long position in the security mentioned were to read this news/tweet, would he/ she be bullish, bearish or neutral on his/her holdings The manually classified feeds are then fed into machine learning models that are taught to imitate language experts in analysing text messages. The completed machine learning models are subsequently used to scrutinise new tweets/news tagged with tickers and assign each tweet/news a story-level sentiment score ranging from À1 to þ1 in real time. Bloomberg does not, however, disclose the details of the models used to determine the sentiment scores because of their proprietary nature. The average firm-level daily sentiment is then extracted from the weighted average story-level sentiment scores in the last 24 h collected and updated every day 10 min before the JSE opens and is calculated as: where: Sent i;t is the news/Twitter sentiment score for firm i at time t; S k i is the sentiment polarity score for tweet/news k that references firm i; C k i is the confidence of tweet/news k that references firm i; Pði; TÞ is the set of all non-neutral tweet/news feeds that reference firm i in the 24 hourperiod, T; N i;T is firm i0s total number of positive or negative tweets/news during period T.
Sentiment ranges from À1, the most negative sentiment to þ1, the most positive sentiment. This means that a sentiment score of 0 denotes neutral sentiment. The news stories used for calculating news sentiment by Bloomberg Inc. come from all sources except Twitter and StockTwits while the tweets used to calculate the Twitter sentiment are gathered from Twitter and StockTwits. The paradox in the sentiment data described above is what score to ascribe to a firm that is not mentioned on Twitter or news stories in a given period. It, therefore, becomes difficult to give a news/Twitter sentiment score if there are missing values in the sentiment score. To see the extent of the missing values in the sentiment, as well as analyst consensus variables, an analysis of the distribution of the missing values by year was made and the results are visualised in Figure 1.
As can be seen in Figure 1 Panel A, in 2015, the extent of missing values was more than 30% of the total 2015 observations, while the news sentiment and analyst consensus variables had missing values constituting less than 10% of the total observations for the period. Removing the year 2015 from the sample leads to the distribution of missing values as depicted in Panel B of Figure 1. The percentage of missing values in 2016 is a little over 7% and falls consistently until the end of the sample period. To ameliorate the effects of high percentages of missing Twitter sentiment data, the sample period used for analysis is restricted from 1 January 2016 to 30 July 2021. Missing values for news and Twitter sentiment data for the sample period are given scores of "0" on the presumption that a company that is not mentioned on the Twitter/Stock Twits platforms as well as in news articles reflects that investors are neutral about the prospects of the company. This approach has also been used in other studies using online investor sentiment (e.g. Sprenger et al., 2014).

Control variables.
In line with other studies (e.g. Gu and Kurov, 2020), various control variables which have been reported to have an effect on analyst recommendations changes are used in the baseline model. Daily volatility (V i;t ) is estimated using intraday price highs and lows in line with the PARK volatility measure (Parkinson, 1980). The PARK estimator's accuracy instinctively emanates from the idea that the intraday price range gives more information regarding future volatility than two arbitrary closing-price points in the series.

MF
Supposing that the stock price follows a simple Brownian model without a constant term, the PARK statistic is calculated as follows: where H t and L t stand for the daily highs and lows of a stock price. PARK volatility has also been used in scholarly articles examining the role of textual sentiment in capital markets (such as Li et al., 2018). To ensure that volume is comparable across firms, abnormal trading volume is used as a control variable and is computed by dividing the difference between trading volume for stock i on day t and the mean volume for stock i across the sample period by the mean volume for stock i across the period. The daily bidask spread (expressed in South African Rands) is the average of the bid-ask spread within a trading day and is used to control for liquidity in line with Gu and Kurov (2020). Firm size is computed as the natural logarithm of the market capitalisation of firm i at time t.
In our econometric models, we also control for macroeconomic developments. According to Schmeling (2009)

Empirical methodology
To examine whether pre-event online investor sentiment significantly influences analyst recommendation changes, this study follows the approach used by Gu and Kurov (2020) which is presented in Equation (3): where ΔRe i;t is the change in the analyst recommendation consensus for firm i at time t Regression controls include firm i's five lags of the daily return, volatility, abnormal trading volume, market capitalisation and the bid-ask spread. We run the regression in Equation (4) using pooled OLS with standard errors clustered by calendar day to account for crosscorrelation between firms in line with Gu and Kurov (2020).
To answer the question: When does investor sentiment influence analyst recommendation changes the most?, quantile regression is used. Quantile regression necessitates the approximation of conditional quantiles of the regressand given a range of predictor variables without splitting the sample (Koenker and Bassett, 1978). The quantile regression estimator also permits the effect of the explanatory variable to fluctuate across the quantiles of the dependent variable. Quantile regression estimators are robust to outliers and they deal with non-linearity without presuming a specific form of the model (Koenker and Bassett, 1978).
Using quantile regression, the conditional quantile function of γ i;t at quantile τ given explanatory variable x i;t is defined as follows: where F ε stands for the distribution of errors and β τ and c τ are the parameters. The coefficients of the τ th conditional quantile regression are approximated as follows: where T indicates the sample size and ρ τ is the check function defined as ρ τ ðεÞ ¼ τε if ε ≥ 0 and ρ τ ðεÞ ¼ ðτ − 1Þε otherwise. This study uses Equation (5) as the baseline equation for the quantile regression model specification as follows: where τ is the τ th quantile in the conditional distribution of the regressand. Equation (6) is the quantile regression model which is estimated to establish when online investor sentiment matters the most for recommendation changes. Nine quantile intervals of analyst recommendation changes between 0.1 and 0.9 are used (see Figure 3).

Descriptive statistics
This section presents a univariate and bivariate analysis of the variables used in the study. Figure 2 shows the distribution of the volume of news articles and tweets per year as well as per day of the week. A similar pattern emerges in the distribution of news articles as well as tweets per year and per day of the week. The distribution per year shows that the largest volume of news articles (447,374) and tweets (185,626) appear in 2018. The distribution by day of the week also shows the same pattern for news articles as it is for tweets. Tweets and news articles have the largest volume on Mondays, fall on Tuesdays and start increasing on Wednesdays. The dip in the volume of news articles and tweets on Tuesday can be ascribed to events that happen during weekends but are incorporated and reported on Monday. Also, it can be seen that the volume of news articles in absolute terms is consistently larger than the volume of tweets. This can be explained by the fact that news articles are collected from a multitude of online sources while tweets are only collected from Twitter and StockTwits. Table 1 shows the distribution of the analyst recommendation changes. Consistent with the distribution of recommendation changes from other studies that have been done, most of the recommendations were confirmations of the previous recommendation scores (no change). The number of upgrades (2,673) for the whole sample period is slightly higher than the number of downgrades (2,639). The summary statistics, as well as the correlation coefficients of the variables, are shown in Tables 2 and 3 respectively.
As can be seen in Table 3, Twitter sentiment and news sentiment have a low positive (ρ ¼ þ0:095; p < 0:01) but statistically significant Pearson correlation coefficient between MF them. This low correlation coefficient shows that the two proxies for online investor sentiment measure different phenomena. The positive correlation is a signal that both proxies of investor sentiment might be affected by the same macroeconomic environment. Analyst recommendation changes and news sentiment have a positive (ρ ¼ þ0:013) and statistically significant relationship (p < 0:01). However, the correlation coefficient between analyst recommendation changes and Twitter sentiment is not significant at any conventional level of statistical significance. This provides elementary evidence that there might be a relationship between news sentiment and analyst recommendation changes which should be investigated using a robust empirical specification.
4.2 Results from the empirical specifications 4.2.1 Does online sentiment influence analyst recommendation changes?. Table 4 shows the results from the econometric model designed to examine if online investor sentiment significantly influences analyst recommendation changes. The results show that pre-event Twitter sentiment does not significantly influence analyst recommendation changes as the coefficient for Twitter sentiment is not statistically significant at any of the conventional levels of significance. On the other hand, pre-event news sentiment positively and    The results show that financial analysts are likely to be guided by news sentiment, which is usually verifiable and credible because of the employment of editors who usually verify facts surrounding a story before it goes online. The "wisdom of the Twitter crowds" does not affect the rating of a company by financial analysts. These results are contrary to Gu and Kurov (2020) who reports a positive and significant relationship between pre-event Twitter sentiment and analyst recommendation changes.
The COVID-19 pandemic is a black swan event that led to various changes in the financial markets. The pandemic led to an increase in the number of retail investors across the globe as well as to increases in the consumption of news using online platforms as many countries were placed on national lockdowns. To capture the possible effects of the change in the environment, the sample period is split into two periods; the pre-COVID-19 period and the COVID-19 period. In South Africa, the first COVID-19 case was reported on 5 March 2020. The sample period is therefore split into two sample periods using 4 March 2020 as the breakpoint. The Pre-COVID period is defined as the period between 1 January 2016 and 4 March 2020 while the COVID period is defined as the period between 5 March 2020 and 30 July 2021. The results after splitting the sample are shown in Table 5.
Analyst recommendation changes and online sentiment (full sample) Table 3. Correlation coefficients between variables period (β ¼ 0:0009) [4]. Thus, it is clear from the results that news sentiment loses information quality in influencing analyst recommendation changes during the pandemic. This could be a reflection of the analysts' reliance on their private information rather than relying on public news in an uncertain environment. 4.2.2 When does online investor sentiment matter the most for recommendation changes. The results from the Ordinary Least Squares in Section 4.2.1 show that news sentiment has a positive significant effect on analyst recommendation changes. This section seeks to examine when news sentiment matters the most for analyst recommendation changes. The results from the quantile regression model with the same control variables as used in the OLS regression model are shown in Table 6. As the relationship between Twitter sentiment and analyst recommendation in the mean presented in Section 4.2.1, the results in Table 6 show no relationship between Twitter sentiment and recommendation changes across the conditional distribution of the analyst recommendation changes. This means that irrespective of whether the upgrades and downgrades recommended by financial analysts are huge or moderate, Twitter sentiment does not significantly affect their decisions. This, therefore, shows that Pre COVID-19 COVID-19 Analyst recommendation changes (1) (2) (1) (2)  A different pattern emerges when considering the effect of news sentiment on analyst recommendation changes across the conditional distribution of the former. Firstly, pre-event news sentiment is positively and significantly associated with recommendation changes across all the quantiles of recommendation changes. Secondly, the effect of pre-event news sentiment on analyst recommendations is high (β ¼ 0:0288; p < 0:01Þ at moderate analyst recommendation changes (in the middle of the analyst recommendation changes; τ ¼ 0:5).
Finally, the coefficients of news sentiment are statistically significant at the 1% level in the middle of the quantiles (τ ¼ ½0:2 : 0:9) while in the lower quantile (τ ¼ 0:1) and the upper quantile (τ ¼ 0:9), coefficients are only significant at the 5% level. The results show that preevent news sentiment is important to analyst recommendation changes when the recommendation changes are moderate (for example upgrading from a score of 1-2 or vice versa). When the analyst changes are large (for example upgrading from 1 to 5), news sentiment is less important to the financial analysts as they will have to depend on significant evidence from analysis of the fundamentals of a company to change firm prospects from a strong sell to a strong buy, for example. The results of the effect of pre-event news sentiment on analyst recommendation changes are visualised in Figure 3: As shown in Figure 3, the lowest coefficients for news sentiment are found in the lowest and highest quantiles of analyst recommendation changes. Thus, the effect of news sentiment on analyst recommendation changes is not uniform but is heterogeneous as shown by differences in the absolute values of the sentiment coefficients as well as the levels of significance. Figure 3 also shows that specifications using OLS do not capture the heterogeneity at various quantiles of recommendation changes. The OLS estimator only coincides with quantile estimators at τ ∈ ½0:4; 0:5; 0:6 and for the remainder of the analyst recommendation change quantiles, the coefficients of news are outside the 95% confidence interval bands of the OLS estimates.
4.2.3 Robustness. To ensure that our results are not driven by specific methodological specifications, we institute several robustness checks. According to Gu and Kurov (2020), there are times when financial analysts tend to release recommendations before the market opens. This is corroborated by Bradley et al. (2020) who report that in the United States of America, "The Fly on the Wall", a digital publisher of financial news leaks almost half of analyst recommendations changes before the stock market opens on the recommendation release date. It is therefore likely that recommendations announced on day t could affect online News t−1 =Twitter t−1 which measures firm i's online investor sentiment from market open on day t − 1 to market open on day t. To ameliorate complications from such reverse causality, online investor sentiment released on day t − 1 (News t−2 =Twitter t−2 in the regression models) is used. The results from this model specification are qualitatively similar and are shown in Tables A1, A2 and A3 in the Appendix.
Secondly, the observations with "no changes" (reinstatement of the previous score) in the analyst recommendation changes are removed and analysis is done on the upgrades and downgrades only. Thirdly, according to Kim et al. (2021), the announcement effects of analyst recommendation revisions may be mixed with the effects of other news releases like earnings announcements. We extract all earnings announcement dates from Bloomberg Inc. that take place within our sample period and exclude analyst recommendation revisions that occur within a 3-day event window of earnings announcements. This resulted in a dataset with recommendation announcements that occur within three days before and after earnings announcements. Fourthly, instead of imputing missing Twitter/news sentiment data with "0", missing values are imputed using Multiple Imputation by Chained Equations (MICE). The few missing values of the Twitter/news sentiment were filled by estimating their conditional probability by using existing data. The results using models that are sensitive to the above robustness checks produce qualitatively similar results which are not reported for brevity but are available upon request.
Finally, we follow the methodology used by Corredor et al. (2013) [5] to analyse the effect of news sentiment on analyst recommendations on portfolios formed using quintiles of the sizes and Book to Market (BTM) of the sampled companies. Like Corredor et al. (2013), we define a firm as a high growth stock if it falls within the first quintile of BTM. Our results show that the influence of news sentiment is greater in small stocks as well as high growth stocks. This shows that the effect of news sentiment on analyst recommendations is more pronounced in stocks that render them more difficult to value or arbitrage. This implies that the effect of news sentiment on returns may cascade to analyst forecasts thereby generating bias in the level of analyst recommendations. This corroborates earlier studies on studies that have investigated the effect of sentiment on analyst recommendation by disaggregating firms using specific stock characteristics (e.g. Corredor et al., 2013).

Conclusion
The paper aimed to examine whether event time online investor sentiment influences analyst recommendation changes using a sample of companies listed on the Johannesburg Stock Exchange All Share Index. Using OLS with standard errors clustered at calendar days, the results show that lagged news sentiment significantly influences analyst recommendation changes while there is no evidence of a significant effect of Twitter sentiment on analyst recommendation changes. This was followed up by an examination of the relationship between lagged online sentiment and analyst recommendation changes across the conditional distribution of the latter. The results show that investor sentiment influences analyst recommendation changes when the consensus changes are moderate while the effect at both tails of the analyst change distribution is less significant both statistically and in absolute terms. It can therefore be implied that news sentiment is relied upon by financial analysts to make moderate upgrades and downgrades while extreme changes are less influenced by investor sentiment. Investors should therefore consider using supplementary sources of information when analysts institute moderate changes on a firm. Future studies could also create a composite index of online investor sentiment using principal component analysis on Twitter sentiment and news sentiment. Notes 1. A report by the Mail and Guardian estimates that by 2025 retail investors on the JSE will constitute 25% of the investors (https://mg.co.za/special-reports/2021-08-16-the-implications-of-democratisedinvesting/). This allows us to estimate that at present, institutional investors account for more than 75% of the total investors on the JSE.