getFin_ts: getFin_ts

Description Usage Arguments Details Value Note Author(s) Examples

Description

get financial factors throug a tinysoft expression, which could be simple or more complicated.

Usage

1
2
3
4
getFin_ts(TS, funchar, varname = funchar, Rate = 1, RateDay = 0, datelist,
  stockID, drop)

TS.getFin_ts(TS, funchar, varname = funchar, Rate = 1, RateDay = 0)

Arguments

TS

a TS object

funchar

a vector of character string, giving a tinysoft expression to get the financtial indicators of the stock. The expression can be made simply by replaceing the specified reportdate in the stock-data-expert expression by 'Rdate'. e.g. change Last12MData(20091231,46002) to Last12MData(Rdate,46002).

varname

character string, giving the name of the returned variables

Details

Note that the tinysoft function must contain ONLY two system parameters(no more!):pn_stock() and pn_date() ,which is supplyed from the two fields in the TS respectively.Also,the function must contain a expression of 'Rdate:=NewReportDateOfEndT2(sp_time())' to get the newest Rdate of sp_time.

Value

A TSF object,a dataframe, containing at least cols:date(with class of Date),stockID,varname,Rdate

Note

Note that the tinysoft function must contain ONLY two system parameters(no more!):pn_stock() and pn_date() ,which is supplyed from the two fields in the TS respectively. Also,the function must contain a expression of 'Rdate:=NewReportDateOfEndT2(sp_time())' to get the newest Rdate of sp_time.

Author(s)

Ruifei.Yin

Examples

1
2
3
4
5
6
TS <- getTS(getRebDates(as.Date('2011-03-17'),as.Date('2012-04-17')),'EI000300')
TSF <- TS.getFin_ts(TS,"ReportOfAll(9900416,Rdate)")
TSF2 <- TS.getFin_ts(TS,"GrowthOfNReport(@LastQuarterData(DefaultRepID(),9900003,0),Rdate,3,1)")
TSF3 <- TS.getFin_ts(TS,"StockAveHsl2(20)+reportofall(9900003,Rdate)")
funchar <- c("ReportOfAll(9900416,Rdate)","StockAveHsl2(20)+reportofall(9900003,Rdate)")
TSF4 <- TS.getFin_ts(TS, funchar)

raphael210/QDataGet documentation built on May 26, 2019, 11:02 p.m.