blotter is an R package typically used with the R package quantstrat (as a dependency package for quantstrat). Blotter provides transaction-oriented infrastructure for constructing transactions, portfolios and accounts for trading systems and simulation in R. blotter is under active development at https://github.com/braverock/blotter
Questions tagged [blotter]
71 questions
1
vote
1 answer
Referencing TxnPrice from addTxn() in blotter for trade exit
I am wanting to backtest a trade exit within quantstrat/blotter where I reference the price (inside a loop) that the latest blotter entry transaction was made at. I am wanting to add a rule that if the latest trade has fallen by eg 5% since…

RichS
- 659
- 12
- 19
1
vote
1 answer
Read a list to get name of xts object
I'm trying to work through a version of Guy Yonlin's excellent example code for quantstrat & blotter but make it work for a set of portfolios. Unfortunately I'm stuck trying to read a list of symbols and get R to access the actual xts data that got…

LGTrader
- 2,349
- 4
- 23
- 29
1
vote
1 answer
R blotter: Error in get(Symbol, pos=env): object ... not found
Ok I've read through the documentation, the updated slides from Guy Yollin and all my past posts, but I cannot find an answer to this problem. After my for loop I still get an error that the object 'USDCHF' cannot be found.
Here's my…

MichiZH
- 5,587
- 12
- 41
- 81
0
votes
1 answer
react-text-fun rendering text twice?
I've been playing around with some libraries and tested out react-text fun. I placed the blotter script in my html file and installed the library. When I test out an effect, I get two rendered elements on my page. Any ideas on how to fix…

Kade
- 5
- 3
0
votes
1 answer
Blotter & Quantstrat - Buy only strategy without any exit
I am trying to implement a buy and hold strategy without any exit.
Simple example: using sigFormula to buy when both RSI is long and SMA(sigcomparison) is long.
Till here, the strategy throws all the trades and it works perfectly fine.
However, I…

Amrith
- 1
- 1
0
votes
1 answer
I am not able to install quantstrat package in r
I have just downloaded r and I am trying to download quantstrat. The only problem is that when I run the following code:
install.packages("devtools")
require(devtools)
install_github("braverock/blotter")…
0
votes
2 answers
Unable to install blotter or quantstrat for R 4.0.2, despite using GitHub Repository
Having a difficult time installing blotter for 4.0.2.
I run the following code:
require(devtools)
install_github("braverock/blotter")
install_github("braverock/quantstrat")
I receive the following error message:
Failed to install 'blotter' from…

rocc
- 153
- 1
- 7
0
votes
0 answers
How do I import Blotter.js into my React.js application?
I'm trying to use Blotter.js in my React application, but I can't find out how to define the Blotter class in my React application.
I exported this codepen that tests Blotter.js (https://codepen.io/jgordon-orange/pen/oEGxpp) and it works locally as…

CrumrineCoder
- 157
- 1
- 1
- 7
0
votes
2 answers
Building Tools are missing in RStudio
First of all, I am working on a Mac. I am trying to install Blotter from GitHub. I found several descriptions of how to do that but my RStudio tells me that I am missing Building tools and gives me a link…

tbacher
- 1
- 2
0
votes
0 answers
Un- and Reinstall Quantstrat for new and clean setup R
I’ve been working with Quantstrat for the last 3 weeks and trying to understand ever step the functions takes and how it uses the different environments.
In this learning process, I played around with the code a lot. Now I got to a point where my…

Andy Parzyszek
- 131
- 7
0
votes
0 answers
R: Bizarre Behavior with XTS objects
EDIT(1): This is the sessionInfo():
> sessionInfo()
R version 3.4.2 (2017-09-28)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 10 x64 (build 17134)
Matrix products: default
locale:
[1] LC_COLLATE=English_United States.1252
[2]…

Sean Sinykin
- 542
- 4
- 22
0
votes
0 answers
quantstrat_0.10.7 warning message: .updatePosPL / Modifies end results
I was previously using quantsrat_0.9.1739 & blotter_0.9.1741 for some time and it worked fine until I updated them to the latest version 0.10.7 with blotter 0.12.4.
Most of the simulations that I previously wrote throw in the following message:…

Arnaud Pallini
- 1
- 1
0
votes
0 answers
Quantstrat / Blotter dims error when running Trade Statistics
There is an xts object generated from a txt file. It contains 5 rows: Open, High, Low, Close, S_Base. S_Base is a binary signal which is TRUE (equal to 1) when Low = Close. Thought to make a minimum reproducible example of 55 rows. It has 4 TRUE…

Krug
- 1,003
- 13
- 33
0
votes
1 answer
Xts conversion fails on update from xts 0.9.7 to 0.10.0
Dataframe to xts conversion fails on update from xts 0.9.7 to 0.10.0.
#THIS WORKS (uses xts 0.9.7):
library(xts)
DFX <- structure(list(DateTime = structure(list(sec = c(0, 0, 0), min = c(10L, 0L, 5L), hour = c(17L, 18L, 18L), mday =…

Krug
- 1,003
- 13
- 33
0
votes
1 answer
Time series Matrix multiplication for portfolio return calculation using R
I have a high frequency trading dataset of 10 stocks between 11:00 am to 11:30 am, which I have aggregated to 30 sec interval.
Subsequently I have calculated the return of these 10 stocks.
How to I perform matrix multiplication of the below time…

Abhishek
- 95
- 1
- 6