make_return_file: Make return file

View source: R/make_return_file.R

make_return_fileR Documentation

Make return file

Description

Helper function to create a regular return file

Usage

make_return_file(DATA, FREQ = 1, IMPUTATION = FALSE, CUTOFF = 10, ALIGN = TRUE)

Arguments

DATA

A data.table with structure as provided in the example.

FREQ

The highest possible frequency. Defaults to 1 for a frequency of 1 second.

IMPUTATION

Should missing values be imputed? If TRUE, then na_locf will be used. Defaults to FALSE.

CUTOFF

The number of standard deviations of log returns around which data should be kept. Defaults to 10, s.t. observations outside +-10 SD will be omitted.

ALIGN

Should the data be aligned to round timestamps? Defaults to TRUE.

Value

Outputs a cleaned return file.


YalDan/hf.econometrics documentation built on May 10, 2024, 2:18 a.m.