library(dplyr)
library(stats)
library(magrittr)
library(readr)
library(lazytrade)
path_data <- normalizePath(tempdir(),winslash = "/")
data(price_dataset_big)
#option
#mt_classes = c('BUN', 'BEN', 'RAN','BUV', 'BEV', 'RAV')
#mt_classes = c('BUN', 'BEN', 'RAN')
#clust_method = 'hclust'
#clust_opt = 'ward'
#build dataset for Market Type detection without rule based check
ai_class_rand <- mt_stat_transf(indicator_dataset = price_dataset_big,
num_bars = 64,
timeframe = 60,
path_data = path_data,
mt_classes = c('BUN', 'BEN'),
clust_method = 'kmeans',
clust_opt = 'complete',
rule_opt = FALSE)
#use rule base check
ai_class_rule <- mt_stat_transf(indicator_dataset = price_dataset_big,
num_bars = 64,
timeframe = 60,
path_data = path_data,
mt_classes = c('BUN', 'BEN'),
clust_method = 'kmeans',
clust_opt = 'complete',
rule_opt = TRUE)
Run the code above in your browser using DataLab