<div dir="ltr"><div style>require(raster)</div>## criando um raster <div>r <- raster(ncol=20,nrow=20)<br><div style>## atribuindo valores</div><div>r[] <- (1:ncell(r))*100</div><div style>## linha, coluna, celula, valor</div>
<div>cbind(rowColFromCell(r,1:ncell(r)), 1:ncell(r),getValues(r))<br></div></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">2013/6/20 Elias Krainski <span dir="ltr"><<a href="mailto:eliaskrainski@yahoo.com.br" target="_blank">eliaskrainski@yahoo.com.br</a>></span><br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Oi Alex,<br>
<br>
Veja este exemplo aplicado ao raster do exemplo da funcao citada.<br>
<br>
require(raster)<br>
example(rasterToPolygons)<br>
<br>
pol@data$i <- col(matrix(1L,36,18))[which(r@<u></u>data@values>6)]<br>
pol@data$j <- row(matrix(1L,36,18))[which(r@<u></u>data@values>6)]<br>
<br>
head(pol@data, 3)<br>
r[1, head(pol@data, 3)$j]<br>
<br>
tail(pol@data,3)<br>
r[18, tail(pol@data,3)$j]<div class="HOEnZb"><div class="h5"><br>
<br>
______________________________<u></u>_________________<br>
R-br mailing list<br>
<a href="mailto:R-br@listas.c3sl.ufpr.br" target="_blank">R-br@listas.c3sl.ufpr.br</a><br>
<a href="https://listas.inf.ufpr.br/cgi-bin/mailman/listinfo/r-br" target="_blank">https://listas.inf.ufpr.br/<u></u>cgi-bin/mailman/listinfo/r-br</a><br>
Leia o guia de postagem (<a href="http://www.leg.ufpr.br/r-br-guia" target="_blank">http://www.leg.ufpr.br/r-br-<u></u>guia</a>) e forneça código mínimo reproduzível.<br>
</div></div></blockquote></div><br><br clear="all"><div><br></div>-- <br><div dir="ltr"><div><font style="font-family:arial">###############################################################</font><br><span style="font-family:arial;font-size:small">## </span><span style="font-size:11px;text-align:center;background-color:rgb(239,239,239);color:rgb(150,150,150);font-family:Verdana,Arial,Helvetica,sans-serif;line-height:13px">Jônatan Dupont Tatsch</span></div>
<div><span style="font-family:arial;font-size:small">## </span><span style="color:rgb(150,150,150);font-family:Verdana,Arial,Helvetica,sans-serif;font-size:10.909090995788574px;line-height:12.997159004211426px;text-align:center;background-color:rgb(239,239,239)">Professor do Departamento de Física</span><font face="arial" style="font-size:small"><br>
</font></div><div><span style="font-size:small;font-family:arial">## </span><span style="color:rgb(150,150,150);font-family:Verdana,Arial,Helvetica,sans-serif;font-size:10.909090995788574px;line-height:12.997159004211426px;text-align:center;background-color:rgb(239,239,239)">Centro de Ciências Exatas e Naturais (CCNE)</span><br>
</div><div><span style="font-size:small;font-family:arial">## </span><span style="color:rgb(150,150,150);font-family:Verdana,Arial,Helvetica,sans-serif;font-size:10.909090995788574px;line-height:12.997159004211426px;text-align:center;background-color:rgb(239,239,239)">Universidade Federal de Santa Maria</span></div>
<div><span style="font-family:arial;font-size:small">## </span><span style="font-size:11px;text-align:center;background-color:rgb(239,239,239);color:rgb(150,150,150);font-family:Verdana,Arial,Helvetica,sans-serif;line-height:13px">Faixa de Camobi, Prédio 13 - Campus UFSM - </span><span style="font-size:11px;text-align:center;background-color:rgb(239,239,239);color:rgb(150,150,150);font-family:Verdana,Arial,Helvetica,sans-serif;line-height:13px">Santa Maria, RS, Brasil - 97105-900</span><br>
</div><div style="font-family:arial;font-size:small">## <span style="font-size:11px;text-align:center;background-color:rgb(239,239,239);color:rgb(150,150,150);font-family:Verdana,Arial,Helvetica,sans-serif;line-height:13px">Telefone: +55(55)33012084</span></div>
<div style="font-family:arial;font-size:small">## <span style="font-size:11px;text-align:center;background-color:rgb(239,239,239);color:rgb(150,150,150);font-family:Verdana,Arial,Helvetica,sans-serif;line-height:13px"><a href="http://www.ufsm.br/meteorologia" target="_blank">www.ufsm.br/meteorologia</a></span></div>
<div style="font-family:arial;font-size:small">###############################################################</div></div>
</div>