[R-SIG-Finance] Empty indicator / plot.window: need finite 'ylim' values
Daniel Cegiełka
d@n|e|@ceg|e|k@ @end|ng |rom gm@||@com
Mon Aug 17 20:02:04 CEST 2020
> On 17 Aug 2020, at 19:37, Joshua Ulrich <josh.m.ulrich using gmail.com> wrote:
>
> On Mon, Aug 17, 2020 at 12:33 PM Daniel Cegiełka
> <daniel.cegielka using gmail.com <mailto:daniel.cegielka using gmail.com>> wrote:
>>
>>
>>
>>> On 17 Aug 2020, at 04:55, Rasmus Liland <jral using posteo.no> wrote:
>>>
>>> Dear Mike,
>>>
>>> if I change this line
>>>
>>> plot (chart_Series (sample.xts[,1], subset=subset, TA=ta))
>>>
>>> to
>>>
>>> plot(chart_Series(sample.xts[subset,1], TA=ta))
>>>
>>> A plot appears. No errors. Was this
>>> what you were looking for?
>>>
>>
>>
>> Guys :)
>>
>> chart_Series() is a plot env/func, so plot(chart_Series()) make no sense :)
>>
> Except that it is necessary to wrap chart_Series() in a call to plot()
> if you call it from within a function, for loop, or any other
> situation where R's auto-printing is disabled.
>
I agree, but in this example earlier it was pointless.
https://github.com/joshuaulrich/quantmod/blob/master/R/replot.R#L202
> c <- quantmod::current.chob()
> str(c)
Classes 'replot', 'environment' <environment: 0x7f9cbdaa8fd8>
So print.replot() will call plot.replot() automatically.
> Cheers,
> Josh
>
>
>>
>> Try:
>>
>> chart_Series(sample.xts[subset,1], TA=ta)
>>
>> ?chart_Series
>>
>> But your problem is here:
>>
>> sample.xts[subset, 2]
>>
>>
>> Best,
>> Daniel
>>
>>
>>
>>
>>> /Rasmus
>>> _______________________________________________
>>> R-SIG-Finance using r-project.org mailing list
>>> https://stat.ethz.ch/mailman/listinfo/r-sig-finance
>>> -- Subscriber-posting only. If you want to post, subscribe first.
>>> -- Also note that this is not the r-help list where general R questions should go.
>>
>> _______________________________________________
>> R-SIG-Finance using r-project.org <mailto:R-SIG-Finance using r-project.org> mailing list
>> https://stat.ethz.ch/mailman/listinfo/r-sig-finance <https://stat.ethz.ch/mailman/listinfo/r-sig-finance>
>> -- Subscriber-posting only. If you want to post, subscribe first.
>> -- Also note that this is not the r-help list where general R questions should go.
>
>
>
> --
> Joshua Ulrich | about.me/joshuaulrich <http://about.me/joshuaulrich>
> FOSS Trading | www.fosstrading.com <http://www.fosstrading.com/>
[[alternative HTML version deleted]]
More information about the R-SIG-Finance
mailing list