The problem is that you need to open the png device, call your plots,
and then close the device. You would do the same e.g. with a pdf.
Try something like this:
##
library(PerformanceAnalytics)
library(quantmod)
library(png)
png("plot-1.png", width=1000, height=600)
Hi all I want to save a code on a png but it saves me a png with 0k
(nothing on the plot) but I see it on R-Studio. No error is happening, what
should be happening?
Many thanks for your help
library(PerformanceAnalytics)
library(dplyr)
library(tibble)
library(lubridate)
Brian,
You're right, of course. But the Roll's model was an influential work in 1980s
when the bid/ask prices were not easily available (if at all). But the
transactional prices were available ( 'time and sales' tapes). So, this model
was a nice and useful theoretical exercise.
Alec
I am not aware of any bid-ask spread estimators in R. I would be interested
to know the intention with estimated bid-ask spreads (and how they compare
with actual spreads) as they do sound dangerous if they were to be used in
any system/model. The quoted papers are quite old, one dating back to
Ajay,
The method you are proposing is easy to write, the authors flat out say
that they didn't really bother to check how accurate their measure is,
but what little checking they do gives highly *implausible* results.
They also say that it only makes sense for liquid instruments (for
which
perhaps something like:
https://onlinelibrary.wiley.com/doi/full/10./j.1540-6261.1984.tb03897.x
?
is easy to write.
On Tue, 28 Jul 2020 at 23:10, diego peroni
wrote:
> Hi All,
>
> I’m looking for a function in R to estimate Bid/Ask Spreads of stocks
> using Daily candlesticks.
>
> Can
To expand on what Brian said, imagine a very illiquid stock that just
trades once on the bid. No range, but probably a very wide bid/ask spread.
On the other hand imagine a very liquid stock highly correlated to the
market on a day with a large range- still will have a small bid/ask spread.
On
Hi there,
You can calculate the Corwin-Schultz (CS) spread estimator.
https://onlinelibrary.wiley.com/doi/abs/10./j.1540-6261.2012.01729.x
One of the authors provides spreadsheets with calculations in Excel. It
should not take much effort to put in R.
You should notice that low-frequency
On Tue, 2020-07-28 at 19:40 +0200, diego peroni wrote:
> I’m looking for a function in R to estimate Bid/Ask Spreads of stocks using
> Daily candlesticks.
>
> Can anyone suggest some implemetations?
Diego,
I would like to help you, but what you are asking for is simply impossible.
Daily
Hi All,
I’m looking for a function in R to estimate Bid/Ask Spreads of stocks using
Daily candlesticks.
Can anyone suggest some implemetations?
Thanks
Diego
___
R-SIG-Finance@r-project.org mailing list
10 matches
Mail list logo