Learn R Programming

lazytrade (version 0.3.9)

record_policy_mt: Record Reinforcement Learning Policy for Market Types

Description

Function will write a policy 'decision' to the csv file specific for each Expert Advisor

Usage

record_policy_mt(
  x,
  trading_system,
  path_terminal,
  fileName = "SystemControlMT"
)

Arguments

x

- Dataframe containing columns MarketType and Policy

trading_system

- numeric vector of lenght 1 with Trading System Magic Number information

path_terminal

- string, path to the terminal where this Policy/Decision must be written

fileName

- string, desired control file prefix e.g. 'SystemControlMT'

Value

nothing is returned but function will write csv file to the supplied directory

Examples

Run this code
# NOT RUN {

library(stringr)
data(policy_tr_systDF)

dir <- normalizePath(tempdir(),winslash = "/")

record_policy_mt(x = policy_tr_systDF,
                 trading_system = 8118101,
                 path_terminal = dir,
                 fileName = "SystemControlMT")


# }

Run the code above in your browser using DataLab