<div dir="ltr"><div dir="ltr">That's great, thank you both and have a good day everyone!<div>Francesca</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">Il giorno mar 24 mag 2022 alle ore 17:04 C Hamilton <<a href="mailto:adenaculture@gmail.com">adenaculture@gmail.com</a>> ha scritto:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Once you have your centroids you can use the Lat Lon Tools plugin and run the "Point Layer to Fields" algorithm to extract the geometry and add it to one or two attribute fields. You can also specify the CRS that you want it in and what format (ie. decimal degrees, DMS and a lot of other formats) you want it in.<div><br></div><div>Best wishes,</div><div><br></div><div>Calvin</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, May 24, 2022 at 2:53 PM Thayer Young via Qgis-user <<a href="mailto:qgis-user@lists.osgeo.org" target="_blank">qgis-user@lists.osgeo.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div><div style="font-family:"Helvetica Neue",Helvetica,Arial,sans-serif;font-size:13px"><div></div>
        <div dir="ltr">Hi Francesca,</div><div dir="ltr"><br></div><div dir="ltr">Assuming that your layer has a geographic coordinate system like 4326. And you have found your centroids already:<br></div><div dir="ltr">Use the field calculator to add a new or virtual field with a numeric data type, e.g. double, and name it something like "lat". Then in the expression area enter the expression: $y      <br></div><div dir="ltr">and press OK. Do the same for "lon" and the expression will be: $x     <br></div><div dir="ltr"><br></div><div dir="ltr">If you want to find the centroid of a polygon and its latitude in one step your expression would be: y<span>(centroid($geometry))     </span><br></div><div dir="ltr">For longitude it would be: <span>x(centroid($geometry))         <br></span></div><div dir="ltr"><br></div><div dir="ltr">Note that different methods will give you different coordinates for your centroid. So you may need to use a spatial join to do your match. <br></div><div dir="ltr"><br></div><div dir="ltr">-Thayer</div><div dir="ltr"><br></div><div><br></div>
        
        </div><div id="gmail-m_7534613716604245926gmail-m_3814153421139375998ydpa16bbee7yahoo_quoted_3455132721">
            <div style="font-family:"Helvetica Neue",Helvetica,Arial,sans-serif;font-size:13px;color:rgb(38,40,42)">
                
                <div>
                    On Tuesday, May 24, 2022, 06:22:46 AM EDT, <a href="mailto:qgis-user-request@lists.osgeo.org" target="_blank">qgis-user-request@lists.osgeo.org</a> <<a href="mailto:qgis-user-request@lists.osgeo.org" target="_blank">qgis-user-request@lists.osgeo.org</a>> wrote:
                </div><br><div><div dir="ltr">----------------------------------------------------------------------<br></div><div dir="ltr">Date: Tue, 24 May 2022 09:52:26 +0200<br></div><div dir="ltr">From: Francesca Parente <<a href="mailto:francescaparente.rse@gmail.com" rel="nofollow" target="_blank">francescaparente.rse@gmail.com</a>><br></div><div dir="ltr">To: QGIS User List <<a href="mailto:qgis-user@lists.osgeo.org" rel="nofollow" target="_blank">qgis-user@lists.osgeo.org</a>><br></div><div dir="ltr">Subject: [Qgis-user] visualize and export coordinates of centroids<br></div><div dir="ltr">Message-ID:<br></div><div dir="ltr">    <CAA8dZSc04zGiUy5JZhEARj0+<a href="mailto:ddP1L8z_abcSdXpRS5CYi6oieg@mail.gmail.com" rel="nofollow" target="_blank">ddP1L8z_abcSdXpRS5CYi6oieg@mail.gmail.com</a>><br></div><div dir="ltr">Content-Type: text/plain; charset="utf-8"<br></div><div dir="ltr"><br></div><div dir="ltr">Hello group,<br></div><div dir="ltr"><br></div><div dir="ltr">I would like to ask you what is in your opinion the best way to identify<br></div><div dir="ltr">the lat-lon attributes of derived centroids in order to export them to an<br></div><div dir="ltr">extra-QGis database where corresponding coordinates should match with<br></div><div dir="ltr">identified locations.<br></div><div dir="ltr"><br></div><div dir="ltr">So far I've tried with Geocoding and MMQGIS plugins, but the resulting<br></div><div dir="ltr">attributes table doesn't inlcude the coordinates of geocoded points.<br></div><div dir="ltr"><br></div><div dir="ltr">Thanks a lot for any advice!<br></div><div dir="ltr">Francesca<br></div><div dir="ltr"><br></div><div dir="ltr">-- <br></div><div dir="ltr">----------------------------<br></div><div dir="ltr">Francesca Parente<br></div><div dir="ltr"><br></div></div>
            </div>
        </div></div>_______________________________________________<br>
Qgis-user mailing list<br>
<a href="mailto:Qgis-user@lists.osgeo.org" target="_blank">Qgis-user@lists.osgeo.org</a><br>
List info: <a href="https://lists.osgeo.org/mailman/listinfo/qgis-user" rel="noreferrer" target="_blank">https://lists.osgeo.org/mailman/listinfo/qgis-user</a><br>
Unsubscribe: <a href="https://lists.osgeo.org/mailman/listinfo/qgis-user" rel="noreferrer" target="_blank">https://lists.osgeo.org/mailman/listinfo/qgis-user</a><br>
</blockquote></div>
</blockquote></div><br clear="all"><div><br></div>-- <br><div dir="ltr" class="gmail_signature"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div>----------------------------</div><div><font face="monospace, monospace">Francesca Parente</font></div><div><font face="monospace, monospace"><br></font></div><div><font face="monospace, monospace" size="1">_ <a href="https://phd.uniroma1.it/web/FRANCESCA-PARENTE_nT1602922_IT.aspx" target="_blank">SESS Euro PhD</a> in SocioEconomic and Statistical Studies</font></div><div><font face="monospace, monospace" size="1">_ <a href="https://sep.luiss.it/" target="_blank">Luiss SEP</a> School of European Political Economy</font></div><div><span style="font-family:monospace,monospace;font-size:x-small"><br></span></div><div><span style="font-family:monospace,monospace;font-size:x-small">email: </span><font color="#20124d"><a href="mailto:francescaparente.rse@gmail.com" style="font-family:monospace,monospace;font-size:x-small" target="_blank">francescaparente.rse@gmail.com</a><span style="font-family:monospace,monospace;font-size:x-small"> <br></span><font face="monospace" size="1">       <a href="mailto:parentef@luiss.it" target="_blank">parentef@luiss.it</a></font> </font></div><div><br></div></div></div></div></div></div></div></div></div>