check.colnames: check.colnames

Description Usage Arguments Author(s) Examples

Description

check colnames of an object with data.frame class, eg. TS, TSF, TSFR, ... Return error when the elements of coltest is not contained in the colnames of data

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
check.colnames(data, coltest)

usualcols()

is_usualcols(cols)

guess_factorNames(df, no_factorname = NULL, is_factorname = NULL,
  silence = FALSE)

check.TS(TS)

check.rptTS(rptTS)

check.TSF(TSF)

check.TSFR(TSFR)

check.Port(port)

check.SP(SP)

check.TSS(TSS)

Arguments

data

a dataframe or matrix,with some colnames

coltest

a character vector containing the colnames to be checked

Author(s)

Ruifei.Yin

Examples

1
2
3
4
5
df <- data.frame(a=1,b=2)
check.colnames(df,c("a","b"))
check.colnames(df,c("a","c"))
df <- data.frame(a=1,b=2,c=3,date=9,factorscore=0)
guess_factorNames(df,no_factorname = "c",is_factorname = "factorscore")

QuantAndrew/QUtility documentation built on May 14, 2019, 7:36 a.m.