<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv=Content-Type content="text/html; charset=utf-8">
<meta name=Generator content="Microsoft Word 12 (filtered medium)">
<style>
<!--
/* Font Definitions */
@font-face
{font-family:"Cambria Math";
panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
{font-family:Verdana;
panose-1:2 11 6 4 3 5 4 4 2 4;}
@font-face
{font-family:"Trebuchet MS";
panose-1:2 11 6 3 2 2 2 2 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0cm;
margin-bottom:.0001pt;
font-size:12.0pt;
font-family:"Times New Roman","serif";}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:blue;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{mso-style-priority:99;
color:purple;
text-decoration:underline;}
p
{mso-style-priority:99;
mso-margin-top-alt:auto;
margin-right:0cm;
mso-margin-bottom-alt:auto;
margin-left:0cm;
font-size:12.0pt;
font-family:"Times New Roman","serif";}
span.EstiloDeEmail18
{mso-style-type:personal-reply;
font-family:"Calibri","sans-serif";
color:#1F497D;}
.MsoChpDefault
{mso-style-type:export-only;}
@page Section1
{size:612.0pt 792.0pt;
margin:70.85pt 3.0cm 70.85pt 3.0cm;}
div.Section1
{page:Section1;}
-->
</style>
<!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang=PT-BR link=blue vlink=purple>
<div class=Section1>
<p class=MsoNormal><span style='font-family:"Arial","sans-serif"'>Eu não
consegui rodar isto, o que aconteceu?<o:p></o:p></span></p>
<p class=MsoNormal><span style='font-family:"Arial","sans-serif";color:#1F497D'><o:p> </o:p></span></p>
<p class=MsoNormal><span lang=EN-US style='font-family:"Arial","sans-serif";
color:#1F497D'>> library(Quandl)<o:p></o:p></span></p>
<p class=MsoNormal><span lang=EN-US style='font-family:"Arial","sans-serif";
color:#1F497D'>> Facebook = Quandl('GOOG/NASDAQ_FB', type = "xts")<o:p></o:p></span></p>
<p class=MsoNormal><span lang=EN-US style='font-family:"Arial","sans-serif";
color:#1F497D'>Error in headers$value()[["X-RateLimit-Remaining"]] : <o:p></o:p></span></p>
<p class=MsoNormal><span lang=EN-US style='font-family:"Arial","sans-serif";
color:#1F497D'> subscript out of bounds<o:p></o:p></span></p>
<p class=MsoNormal><span lang=EN-US style='font-family:"Arial","sans-serif";
color:#1F497D'>In addition: Warning message:<o:p></o:p></span></p>
<p class=MsoNormal><span lang=EN-US style='font-family:"Arial","sans-serif";
color:#1F497D'>In Quandl("GOOG/NASDAQ_FB", type = "xts") :<o:p></o:p></span></p>
<p class=MsoNormal><span lang=EN-US style='font-family:"Arial","sans-serif";
color:#1F497D'> It would appear you aren't using an authentication token.
Please visit http://www.quandl.com/help/r or your usage may be limited.<o:p></o:p></span></p>
<p class=MsoNormal><span lang=EN-US style='font-family:"Arial","sans-serif";
color:#1F497D'>> candleChart(Facebook["2016-01::2016-01"])<o:p></o:p></span></p>
<p class=MsoNormal><span lang=EN-US style='font-family:"Arial","sans-serif";
color:#1F497D'>Error in do.call("chartSeries", list(x, subset = subset,
name = name, : <o:p></o:p></span></p>
<p class=MsoNormal><span lang=EN-US style='font-family:"Arial","sans-serif";
color:#1F497D'> </span><span style='font-family:"Arial","sans-serif";
color:#1F497D'>object 'Facebook' not found</span><span style='font-family:"Arial","sans-serif"'><o:p></o:p></span></p>
<div>
<div>
<p class=MsoNormal><span style='font-family:"Verdana","sans-serif";color:#1F497D'><o:p> </o:p></span></p>
<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'><o:p> </o:p></span></p>
<p class=MsoNormal><span style='font-family:"Verdana","sans-serif"'>Senhores,
bom dia!<o:p></o:p></span></p>
</div>
<div>
<p class=MsoNormal><span style='font-family:"Verdana","sans-serif"'><o:p> </o:p></span></p>
</div>
<div>
<div>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Verdana","sans-serif";
color:black'>Há um tutorial interativo sobre o Quandl/R no site Datacamp. É
possível fazer em menos de uma hora e é muito útil.<o:p></o:p></span></p>
</div>
<div>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Verdana","sans-serif";
color:black'><<a
href="https://www.datacamp.com/courses/how-to-work-with-quandl-in-r"
target="_top"><span style='color:#551A8B'>https://www.datacamp.com/courses/how-to-work-with-quandl-in-r</span></a>>.
Entre outras coisas, ensina fazer o gráfico OHLC com o pacote {quantmod}.<o:p></o:p></span></p>
</div>
<div>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Verdana","sans-serif";
color:black'><o:p> </o:p></span></p>
</div>
<div>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Verdana","sans-serif";
color:black'>Embora o curso ensine a obter os dados diretamente da web, você
pode gerar o gráfico a partir de dados próprios, se converter para algum
formato aceito pelo pacote, como xts, por exemplo. <o:p></o:p></span></p>
</div>
<div>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Verdana","sans-serif";
color:black'><o:p> </o:p></span></p>
</div>
<div>
<div>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>### <code r></span><o:p></o:p></p>
</div>
<div>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>my.df <- data.frame(</span><o:p></o:p></p>
</div>
<div>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>Day=c("2015-01-02", "2015-01-05",
"2015-01-06", "2015-01-07", "2015-01-08",
"2015-01-09"),</span><o:p></o:p></p>
</div>
<div>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>Open =c(50.7, 49.7, 49.2, 49.6, 49.0, 50.3),</span><o:p></o:p></p>
</div>
<div>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>High =c(50.8, 49.9, 49.9, 49.6, 50.2, 50.4),</span><o:p></o:p></p>
</div>
<div>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>Low =c(49.5, 48.9, 48.3, 48.5, 48.7, 49.6),</span><o:p></o:p></p>
</div>
<div>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>Close=c(50.2, 49.1, 49.2, 48.6, 50.2, 49.7))</span><o:p></o:p></p>
</div>
<div>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>my.df</span><o:p></o:p></p>
</div>
<div>
<p class=MsoNormal><o:p> </o:p></p>
</div>
<div>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>require(quantmod)</span><o:p></o:p></p>
</div>
<div>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>my.xts <- xts(my.df[,2:5], <a href="http://order.by">order.by</a>=as.Date(my.df$Day))</span><o:p></o:p></p>
</div>
<div>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>candleChart(my.xts, theme="white")</span><o:p></o:p></p>
</div>
<div>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>chartSeries(my.xts)</span><o:p></o:p></p>
</div>
<div>
<p class=MsoNormal><o:p> </o:p></p>
</div>
<div>
<div>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>library(Quandl)<o:p></o:p></span></p>
</div>
<div>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>Facebook = Quandl('GOOG/NASDAQ_FB', type = "xts")<o:p></o:p></span></p>
</div>
<div>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>candleChart(Facebook["2016-01::2016-01"])<o:p></o:p></span></p>
</div>
</div>
<div>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>### </code></span><o:p></o:p></p>
</div>
</div>
<div>
<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Verdana","sans-serif";
color:black'><o:p> </o:p></span></p>
</div>
</div>
<div>
<p class=MsoNormal><br clear=all>
<o:p></o:p></p>
<div>
<div>
<div>
<div>
<div>
<div>
<div>
<div>
<p class=MsoNormal><span style='font-family:"Cambria Math","serif"'></span><span
style='font-family:"Trebuchet MS","sans-serif"'><o:p></o:p></span></p>
</div>
<p class=MsoNormal><span style='font-family:"Arial","sans-serif"'>================================================<br>
Éder Comunello</span><o:p></o:p></p>
<div>
<p class=MsoNormal><span style='font-family:"Arial","sans-serif"'>PhD Student
in Agricultural Systems Engineering (USP/Esalq)</span><o:p></o:p></p>
</div>
<div>
<p class=MsoNormal>Brazilian Agricultural Research Corporation (<span
style='font-family:"Arial","sans-serif"'>Embrapa)</span><o:p></o:p></p>
<div>
<p class=MsoNormal><span style='font-family:"Arial","sans-serif"'>Dourados, MS,
Brazil [</span>22 16.5'S, 54 49.0'W<span style='font-family:"Arial","sans-serif"'>]</span><o:p></o:p></p>
</div>
<div>
<div>
<p class=MsoNormal><o:p> </o:p></p>
</div>
<div>
<p class=MsoNormal><o:p> </o:p></p>
</div>
</div>
<div>
<p class=MsoNormal><o:p> </o:p></p>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<p class=MsoNormal><o:p> </o:p></p>
</div>
</div>
</div>
<br /><br />
<hr style='border:none; color:#909090; background-color:#B0B0B0; height: 1px; width: 99%;' />
<table style='border-collapse:collapse;border:none;'>
<tr>
<td style='border:none;padding:0px 15px 0px 8px'>
<a href="https://www.avast.com/antivirus">
<img border=0 src="http://static.avast.com/emails/avast-mail-stamp.png" alt="Avast logo" />
</a>
</td>
<td>
<p style='color:#3d4d5a; font-family:"Calibri","Verdana","Arial","Helvetica"; font-size:12pt;'>
Este email foi escaneado pelo Avast antivírus.
<br><a href="https://www.avast.com/antivirus">www.avast.com</a>
</p>
</td>
</tr>
</table>
<br />
</body>
</html>