#本地读取通达信数据 readTDXB <- function(stockName) { tdx <-read.csv(file = paste(stockName,".csv",sep = ""),header = FALSE,sep = ",",skip = 2)[,1:6] names(tdx) <- c("DATETIME","Open","High","Low","Close","Volume") tdxxts <- as.xts(tdx[,-1],as.Date(tdx$DATETIME)) return(na.trim(tdxxts)) }