<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=Windows-1252">
<style type="text/css" style="display:none;"> P {margin-top:0;margin-bottom:0;} </style>
</head>
<body dir="ltr">
<div align="left">
<p style="line-height:100%;margin-bottom:0cm;background:transparent none repeat scroll 0% 0%">
Boa tarde listeiros,</p>
<p style="line-height:100%;margin-bottom:0cm;background:transparent none repeat scroll 0% 0%">
<br>
</p>
<p style="line-height:100%;margin-bottom:0cm;background:transparent none repeat scroll 0% 0%">
Estou uma base de dados que tem a coluna TIMESTAMP em ymd_hms, estou criando as colunas meses, dia e hora. Da seguinte forma:</p>
<p style="line-height:100%;margin-bottom:0cm;background:transparent none repeat scroll 0% 0%">
<br>
</p>
<p style="line-height:100%;margin-bottom:0cm;background:transparent none repeat scroll 0% 0%">
input$Year<-format(input2$TIMESTAMP, '%Y')</p>
<p style="line-height:100%;margin-bottom:0cm;background:transparent none repeat scroll 0% 0%">
input$Month<-format(input2$TIMESTAMP, '%m')</p>
<p style="line-height:100%;margin-bottom:0cm;background:transparent none repeat scroll 0% 0%">
input$Day<-format(input2$TIMESTAMP, '%d')</p>
<p style="line-height:115%;margin-bottom:0.5cm;background:transparent none repeat scroll 0% 0%">
input$Hour.S<-formart(input$TIMESTAMP, ‘%H’)</p>
<p style="line-height:115%;margin-bottom:0.5cm;background:transparent none repeat scroll 0% 0%">
No entanto, a coluna da hora aparece zerada. Lembrando que fiz a conversão de string para data:
</p>
<p style="line-height:100%;margin-bottom:0.5cm;background:transparent none repeat scroll 0% 0%">
input$TIMESTAMP<- as.Date(ymd_hms(input$TIMESTAMP))</p>
<p style="line-height:100%;margin-bottom:0.5cm;background:transparent none repeat scroll 0% 0%">
input2$TIMESTAMP<- as.Date(input$TIMESTAMP)</p>
<p style="line-height:100%;margin-bottom:0.5cm;background:transparent none repeat scroll 0% 0%" class="elementToProof">
Ambas meu resultado é 00. Eu preciso que minha saída seja de 00-24, por exemplo, 0.5;1;1.5;...23.5</p>
<p style="line-height:100%;margin-bottom:0.5cm;background:transparent none repeat scroll 0% 0%" class="elementToProof">
Muito Obrigados a todos(@s)<br>
</p>
</div>
<div class="elementToProof" align="left"><font style="font-size:12pt" size="3" face="Franklin Gothic Medium"><font style="" face="Times New Roman"><span style="font-family:Calibri,Arial,Helvetica,sans-serif; color:rgb(0,111,201)"></span><span style="font-family:Calibri,Arial,Helvetica,sans-serif; color:rgb(0,111,201)"></span><br>
</font></font></div>
<div class="elementToProof" align="left"><font style="font-size:12pt" size="3" face="Franklin Gothic Medium"><font style="" face="Times New Roman"></font></font></div>
<div>
<div id="Signature">
<div>
<div id="divtagdefaultwrapper" style="font-size:12pt; color:#000000; font-family:Calibri,Arial,Helvetica,sans-serif">
<div align="center"><font style="font-size:12pt" size="3" face="Franklin Gothic Medium"><font style="" face="Times New Roman"><br>
</font><b><br>
</b></font></div>
</div>
</div>
</div>
</div>
</body>
</html>