[Qgis-user] spatial analysis toolbox - testing for autocorrelation

chris hermansen clhermansen at gmail.com
Mon Aug 14 07:18:29 PDT 2023


Francesca and list,

On Mon, Aug 14, 2023, 02:58 Francesca Parente via QGIS-User <
qgis-user at lists.osgeo.org> wrote:

> Thank you both! I checked that out and tried the suggested installing
> procedure.. but I can't get the command prompt where to type "pip install
> geopandas".
> I think I'm still missing a piece, I'm not so familiar with the python
> environment as you can assume.
>

Here is a useful explanation of using pip in python

https://packaging.python.org/en/latest/tutorials/installing-packages/



> These are the steps I followed:
>
> [image: image.png]
> --->
> [image: image.png]
> Then I clicked on "python3.dll", which downloaded the file I tried to open
> - but got me just another error message in QGis (saying that is an invalid
> data source).
> I searched online for other tips and tutorials, but (besides another
> procedure using fiona) I haven't found anything more specific on this one.
>
> Should I go into the "Scripts" folder and click on "pip.exe" or "pip3.exe"?
> Thanks again for your time and any other inputs you may have!
> Francesca
>

You will want to run python from a command line, not by clicking a dll.

Open your command prompt from the windows menu.


>
> Il giorno ven 11 ago 2023 alle ore 19:20 Thayer Young via QGIS-User <
> qgis-user at lists.osgeo.org> ha scritto:
>
>> Hi Francesca,
>>
>> If you don't know how to install Geopandas, I would like to add to what
>> Paolo said. Geopandas needs to be installed in the python that QGIS is
>> using.
>> You can check the location of the python installation by going to the
>> overall preferences for QGIS (command comma on a Mac, probably control
>> comma on other systems.)
>> From the System tab scroll to the bottom to find the "Current environment
>> variables" scroll down to find PYTHONHOME.
>> This documentation page shows you more with pictures:
>>
>> https://docs.qgis.org/3.28/en/docs/user_manual/introduction/qgis_configuration.html#system-settings
>>
>> Then in Finder or Explorer, etc. you want to find  location in the file
>> system. On a Mac you will need to right click on QGIS in your applications
>> folder and show package contents.  Then continue through the path and
>> double click to open the python3 file.
>> This will bring up a python prompt where you want to type:   pip install
>> geopandas   Then press enter/return. It will run for a while and hopefully
>> say that you successfully installed geopandas. You will probably need to
>> restart QGIS after that.
>>
>> -Thayer
>>
>>
>>
>> On Thursday, August 10, 2023 at 03:00:37 PM EDT,
>> qgis-user-request at lists.osgeo.org <qgis-user-request at lists.osgeo.org>
>> wrote:
>> ----------------------------------------------------------------------
>> Date: Thu, 10 Aug 2023 17:29:39 +0300
>> From: Paolo Cavallini <cavallini at faunalia.it>
>> To: Francesca Parente <francescaparente.rse at gmail.com>, Francesca
>>     Parente via QGIS-User <qgis-user at lists.osgeo.org>, QGIS User List
>>     <qgis-user at lists.osgeo.org>
>> Subject: Re: [Qgis-user] spatial analysis toolbox - testing for
>>     autocorrelation
>> Message-ID: <CA92BEAF-7DFA-479D-BF82-4614BF7DE30D at faunalia.it>
>> Content-Type: text/plain; charset="utf-8"
>>
>> You have to install geopandas.
>> Cheers.
>>
>> Il 10 agosto 2023 17:10:28 EEST, Francesca Parente via QGIS-User <
>> qgis-user at lists.osgeo.org> ha scritto:
>> >Hello everyone!
>> >
>> >I was wondering how to perform spatial autocorrelation tests in QGis and
>> I
>> >downloaded the Spatial Analysis Toolbox
>> ><https://plugins.qgis.org/plugins/spatialanalysistoolbox/> plugin.
>> >I can't even open it thought and immediately got the following error
>> >message:
>>
>> >*Impossibile caricare il plugin 'spatialanalysistoolbox' a causa di un
>> >errore chiamando il metodo classFactory() ModuleNotFoundError: No module
>> >named 'geopandas' Traceback (most recent call last):  File
>> >"C:/OSGEO4~1/apps/qgis/./python\qgis\utils.py", line 335, in _startPlugin
>> >  plugins[packageName] = package.classFactory(iface)  File
>>
>> >"C:/Users/fparente/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\spatialanalysistoolbox\__init__.py",
>> >line 36, in classFactory    from .spatialanalysistoolbox import
>> >SpatialAnalysisToolboxPlugin  File
>> >"C:/OSGEO4~1/apps/qgis/./python\qgis\utils.py", line 799, in _import
>> mod
>> >= _builtin_import(name, globals, locals, fromlist, level)  File
>>
>> >"C:/Users/fparente/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\spatialanalysistoolbox\spatialanalysistoolbox.py",
>> >line 38, in    from .spatialanalysistoolbox_provider import
>> >SpatialAnalysisToolboxProvider  File
>> >"C:/OSGEO4~1/apps/qgis/./python\qgis\utils.py", line 799, in _import
>> mod
>> >= _builtin_import(name, globals, locals, fromlist, level)  File
>>
>> >"C:/Users/fparente/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\spatialanalysistoolbox\spatialanalysistoolbox_provider.py",
>> >line 35, in    from .algorithms.GWR_ import GWR_  File
>> >"C:/OSGEO4~1/apps/qgis/./python\qgis\utils.py", line 799, in _import
>> mod
>> >= _builtin_import(name, globals, locals, fromlist, level)  File
>>
>> >"C:/Users/fparente/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\spatialanalysistoolbox\algorithms\GWR_.py",
>> >line 23, in    import geopandas as gpd  File
>> >"C:/OSGEO4~1/apps/qgis/./python\qgis\utils.py", line 799, in _import
>> mod
>> >= _builtin_import(name, globals, locals, fromlist,
>> >level)ModuleNotFoundError: No module named 'geopandas'Versione Python:
>> >3.7.0 (v3.7.0:1bf9cc5093, Jun 27 2018, 04:59:51) [MSC v.1914 64 bit
>> >(AMD64)] Versione di QGIS: 3.18.2-Z?rich Z?rich, 515138c171 *
>> >
>> >I repeated the download/install procedure, but nothing changed.
>> >Does anybody know how to fix this and/or alternative ways to test for
>> >spatial autocorrelation here?
>> >Thanks a lot and have a good day!
>> >--
>> >----------------------------
>> >Francesca Parente
>> >
>> >_ SESS Euro PhD <https://iris.uniroma1.it/cris/rp/rp54329> in
>> SocioEconomic
>> >and Statistical Studies
>> >_ Linked
>> ><
>> https://www.linkedin.com/in/francesca-parente-55194497/details/publications/
>> >
>> >in
>> >
>> >email: francescaparente.rse at gmail.com
>> >      fparente at regione.lazio.it
>> -------------- next part --------------
>> An HTML attachment was scrubbed...
>> URL: <
>> http://lists.osgeo.org/pipermail/qgis-user/attachments/20230810/e9edad66/attachment-0001.htm
>> >
>>
>> ------------------------------
>>
>> Subject: Digest Footer
>>
>> _______________________________________________
>> QGIS-User mailing list
>> QGIS-User at lists.osgeo.org
>> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
>> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
>>
>>
>> ------------------------------
>>
>> End of QGIS-User Digest, Vol 210, Issue 8
>> *****************************************
>> _______________________________________________
>> QGIS-User mailing list
>> QGIS-User at lists.osgeo.org
>> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
>> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
>
>
> _______________________________________________
> QGIS-User mailing list
> QGIS-User at lists.osgeo.org
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-user/attachments/20230814/d50f4f06/attachment-0001.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image.png
Type: image/png
Size: 18785 bytes
Desc: not available
URL: <http://lists.osgeo.org/pipermail/qgis-user/attachments/20230814/d50f4f06/attachment-0002.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image.png
Type: image/png
Size: 48373 bytes
Desc: not available
URL: <http://lists.osgeo.org/pipermail/qgis-user/attachments/20230814/d50f4f06/attachment-0003.png>


More information about the QGIS-User mailing list