# Chinese Stock Exchange Indexes data and descriptive statistics

I am trying to reproduce the following paper: https://link.springer.com/chapter/10.1007%2F11600930_48

In this study, daily prices from January 4, 2001 to December 31, 2004 for Shanghai Stock Composite Exchange Index and Shenzen Stock Composite Index were chosen. According to the paper, the data for the two market indexes consist of 1200 daily prices.

Simple statistics of the two assets returns are given:

$$\begin{array}{c|c} & \text{R_Shanghai} & \text{R_Shenzen} \\ \hline N(valid) & 1200 & 1200 \\ N(missing) & 23 & 23 \\ mean & .0000287 & -.0001005 \\ Std. Deviation & .0136276 & .0142559 \\ Skewness & .896 & .685 \\ ExcessKurtosis & 7.143 & 6.182 & \\ \end{array}$$

Since it was not specified if simple returns or log-returns were used, I computed both of them with the adjusted prices in order to compare my results with those in the table above.

My results:

$$\begin{array}{c|c} & \text{R_Shanghai} & \text{log_R_Shanghai}& \text{R_Shenze}&\text{log_R_Shenzen} \\ \hline N(valid) & 1041 & 1041 & 943 & 943 \\ N(missing) & 0 & 0 & 498 & 498 \\ mean & -.0004096169 & -.0004936958 & -.0003053767 & -.0004053698 \\ Std. Deviation & .01301102 & .01294434 & .0141957 & .01412052 \\ Skewness & .9678668 & .7995928 & .9042324 & .740062 \\ ExcessKurtosis & 7.918897 & 7.094474 & 6.828122 & 6.124954 & \\ \end{array}$$

Unfortunately, I did not find the same results. Moreover, not even the number of observations is the same between the two dates. Most probably the problem comes from the fact that I did not get the same number of observations and/or maybe also by my computations. I would like to find out why I do not get the same number of observations and the same results as displayed in the first table above.

In the r code below, you will find all the details of how I downloaded the data and of my computations.

require("quantmod") # Package that provides suitable functions for downloading financial data from the web

Shanghai <- getSymbols('000001.SS', auto.assign = FALSE,from = "1900-01-01")
# 000001.SS is the symbol corresponding to SSE Composite Index
Shenzen <- getSymbols('^SZSC1', auto.assign = FALSE,from = "1900-01-01")
# ^SZSC1 is the symbol corresponding to SZSE COMPOSITE INDEX

#renaming the column of interest

#desired window of time
Shanghai <- window(Shanghai, start='2001-01-04', end='2004-12-31')
Shenzen <- window(Shenzen, start='2001-01-04', end='2004-12-31')

#simple returns
r.sha <- Shanghai$$Adjusted/lag(Shanghai$$Adjusted, k=1) - 1
r.she <- Shenzen$$Adjusted/lag(Shenzen$$Adjusted, k=1) - 1

#log-returns
r.log.sha <- log(Shanghai$$Adjusted) - log(lag(Shanghai$$Adjusted, k = 1))
r.log.she <- log(Shenzen$$Adjusted) - log(lag(Shenzen$$Adjusted, k = 1))

#drop NA values
r.sha <- na.omit(r.sha)
r.she <- na.omit(r.she)
r.log.sha <- na.omit(r.log.sha)
r.log.she <- na.omit(r.log.she)

#mean
r.sha.mean <- mean(r.sha)
r.log.sha.mean <- mean(r.log.sha)
r.she.mean <- mean(r.she)
r.log.she.mean <- mean(r.log.she)

# standard deviation
r.sha.sd <- sd(r.sha)
r.log.sha.sd <- sd(r.log.sha)
r.she.sd <- sd(r.she)
r.log.she.sd <- sd(r.log.she)

# skewness function
skewness <- function(x){
mean((x-mean(x))^3)/sd(x)^3
}
apply(r.sha,MARGIN = 2,skewness)
apply(r.log.sha,MARGIN = 2,skewness)
apply(r.she,MARGIN = 2,skewness)
apply(r.log.she,MARGIN = 2,skewness)

# kurtosis function
kurtosis <- function(x){
mean((x-mean(x))^4)/var(x)^2 - 3
}
apply(r.sha,MARGIN = 2,kurtosis)
apply(r.log.sha,MARGIN = 2,kurtosis)
apply(r.she,MARGIN = 2,kurtosis)
apply(r.log.she,MARGIN = 2,kurtosis)


• From 2001/1/4 to 2004/12/31 there are 1041 weekdays (Monday through Fridays), there are 1249 days if we add Saturdays and 1457 total calendar days (inclusing both Saturday and Sunday). So it is clear that your Shangai data is for weekdays and the other includes some weekend days. – noob2 Nov 9 '20 at 11:37