Metadata-Version: 2.3
Name: py_geodetector
Version: 0.1.3
Summary: A simple Python package for the geodetector
Project-URL: Homepage, https://github.com/djw-easy/GeoDetector
Project-URL: Bug Tracker, https://github.com/djw-easy/GeoDetector/issues
Author-email: djw <djweasy@163.com>
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Requires-Python: >=3.7
Description-Content-Type: text/markdown

# A simple Python package for the geodetector 

# Install

```
pip install py-geodetector
```

# Usage

A quick example of geodetector usage is given in the ./example.ipynb.

```python
from py_geodetector import load_example_data, GeoDetector

# load example data
df = load_example_data()

gd = GeoDetector(df)
# factor detect
factor_df = gd.factor_dector()

# interaction detect
interaction_df = gd.interaction_detector()
# or you can generate the interaction relationship as the same time
interaction_df, interaction_relationship_df = gd.interaction_detector(relationship=True)

# ecological detect
ecological_df = gd.ecological_detector()

# risk detect
risk_result = gd.risk_detector()

# plot 
# use a heatmap visualize the interaction detect result, 
# red text means that the ecological detection results show a significant difference
gd.plot(value_fontsize=14, tick_fontsize=16, colorbar_fontsize=14);
```

# Reference

```
@article{wang2010geographical,
  title={Geographical detectors-based health risk assessment and its application in the neural tube defects study of the Heshun Region, China},
  author={Wang, Jin-Feng and Li, Xin-Hu and Christakos, George and Liao, Yi-Lan and Zhang, Tin and Gu, Xue and Zheng, Xiao-Ying},
  journal={International Journal of Geographical Information Science},
  volume={24},
  number={1},
  pages={107-127},
  year={2010},
  publisher={Taylor \& Francis}
}
```