---
# System prepended metadata

title: Project work

---

---
title: "Project work"
subtitle: "Analysis of currency indices using quantitative models"
author: "Alexander Bieri, Nicolas Jaquet"
date: "30 November 2020"
output: 
  pdf_document:
    fig_caption: yes
    toc: true
    toc_depth: 4
    number_sections: true
    highlight: tango

    

---

\newpage
\tableofcontents

# Introduction
There exist a lot of strategies that enable forex traders to determine the perfect time to enter and exit the currency market. Traders are constantly aiming at improving already existing models and to create new ones. This is equally the case for Survista, the company we are dealing with in this paper. 
In our project work we are dealing with a problem of Survista AG. This company is based in Switzerland in the sector of wealth management and financial advisory and has various customers in Switzerland and Germany. Their work consists of a multi-asset class mandate, which means that they invest in all asset classes so that their clients reach their investment goals as easily as possible. As the Survista AG does not have large resources, it continuously optimizes its work and investment processes via automation processes or quantitative approaches. During the restructure process asset displacements can be executed. This process is called currency hedge. Additionally to these quarterly analysis the market is monitored every day in order to hedge all asset classes as quickly as possible in the event of any major price changes, such as in the corona crisis. Even in the absence of a crisis one currency can rise or fall against another. Such changes in exchange rates can have a major impact on portfolios. In order to prevent these risks Survista AG uses various models and approaches to register the indicators of a change as early as possible. 
In this paper we are going to analyze and compare different approaches with real data to draw conclusions.

##Motivation
The authors of this project work are in the bachelor's program of industrial engineering
with specialization in business mathematics. They are interested in the field of economics, which uses mathematical and statistical methods to develop economic theory, models and hypotheses. They are examined in this paper for their reality content.

##Research question

To create different strategies for the Survista AG we will answer the following question:
"Which chosen model provides the most reliable and best forecasts for the different trading strategies?"

In addition four hypotheses are established which accompany the research question to be dealt with:

**Hypothesis 1:** Traditional models (Momentum, REER) still can be used as trading indicators

**Hypothesis 2:** Economic models like value and carry perform better than univariate time series like momentum 

**Hypothesis 3:** The trading pair (long, short) at REER, which has only extreme values, makes more profit than a combination of all currency pairs split by the median

plot(rnorm(20))


{r , message=FALSE, warning=FALSE, echo=F, results='hide', fig.keep=1, fig.cap = '30 day momentum line on the USD/CHF Currency with sell and buy signals'}
library(readxl)
library(drc)
library(TTR)
library(FinancialInstrument)
library(PerformanceAnalytics)
library(pROC)
library(fTrading)
library(quantmod)
library(forecast)
momentum <- read_xlsx("C:/Users/Alexander/OneDrive - ZHAW/Zhaw/PA/data_unlkd.xlsx", 
                      range = "A6:P5404", col_names = FALSE)
names(momentum)[1:16] <- c("Date","USDCHF","EURCHF","JPYCHF","GBPCHF","CADCHF","AUDCHF" ,"EURUSD","JPYUSD","GBPUSD","AUDUSD","CADUSD","JPYEUR","GBPEUR","AUDEUR","CADEUR")
momentum_xts = as.xts(momentum[,-1],order.by = as.Date(momentum$Date))
from_to<-"2010-01-01::2012-01-01"
start_date<-"2010-01-01"
in_sample<-"2012-01-01"
x_all = momentum_xts[paste(start_date,"/",sep="")]#nimm ab 2010
x_in<-x_all[paste("/",in_sample,sep="")]#gehe bis 2015
x_out<-x_all[paste(in_sample,"/",sep="")]
chartSeries(momentum_xts$USDCHF,
            type = "line",
            subset=from_to, name = "Currency Pair USD/CHF",
            theme=chartTheme("white"),
            col = 'grey')
