项目 / pydata/pandas-datareader

pydata/pandas-datareader

行业候选
语言 Python标签 htmldata-analysisdatadatasetstock-datafinancefinancial-datapythonpydatapandasecondbfama-frencheconomic-datafred数据更新 2026-11-20 06:49:16 · 仓库 2026-11-19

一段话介绍

把远程宏观与因子类数据读入 pandas 的库。源文说明公共接口聚焦宏观经济、政策和因子风格数据源,例如 FRED、Fama/French、加拿大银行、世界银行、OECD、Eurostat,以及较新的 `pandas_datareader.macro` 接口。安装执行 `pip install pandas-datareader`,再在 Python 中 `import pandas_datareader as pdr` 并按文档调用相应接口,例如 `pdr.get_data_fred('GS10')`。稳定文档见 [github.io](https://pydata.github.io/pandas-datareader/),也可阅读 [Read the Docs](https://pandas-datareader.readthedocs.io/)。仓库见 [GitHub](https://github.com/pydata/pandas-datareader)。

本站整理,非 GitHub 官方 description。

官方 description(GitHub API 原样)
Extract data from a wide range of Internet sources into a pandas DataFrame.
3,283累计星
698Fork
—峰值日增
0上榜次数
总榜
暂未入榜
日榜
暂未入榜
周榜
暂未入榜
月榜
暂未入榜

官方快照(gh_history.db,2026-11-25):总榜 未进 Top50 · 日榜 未进 Top50 · 周榜未满 7 天基线(官方不生成) · 月榜暂无官方口径;下方四卡为站内趋势聚合(周卡按上榜次数,非官方 7 日增量窗)。

行业与场景 金融 暂无可用场景

更多信息

以下三段按该项目自己的 GitHub README 章节摘录(可合理截断并标明);README 没有对应章节的留空,不编造。

我的用法
通过 pip 安装后即可用 pdr.get_data_fred('GS10') 等接口获取数据,其公开 API 聚焦 FRED、Fama/French、世界银行、OECD、Eurostat 等宏观经济与政策类数据源。
特点或设计要点
运行要求包括 pandas 1.5.3 及以上、lxml,以及 requests 2.19.0 及以上;Python 3.12 及以上若缺 `distutils`,源文说明可通过安装 setuptools 解决。也可从 Git 安装开发版。文档提供稳定版与基于主分支的开发版两套。
局限和适用边界
使用 pandas-datareader 需满足依赖要求,其中 Python 3.12 及以上版本不自带 distutils,需安装 setuptools 解决。
星标走势还差一天的数据,明天就能看到曲线
每天 10:30 记一次星标,连续两天后自动生成曲线
首次发现 — · 最近在榜 2026-07-21 · 语言 Python · 贡献者 —
python

GitHub 项目主页介绍

来自 GitHub 仓库 README / 主页介绍正文,原样摘录,共 2,529 字节。

# pandas-datareader



Macroeconomic and factor-oriented remote data access for pandas.



[![CI Testing](https://github.com/pydata/pandas-datareader/actions/workflows/ci.yml/badge.svg)](https://github.com/pydata/pandas-datareader/actions/workflows/ci.yml)

[![PyPI](https://img.shields.io/pypi/v/pandas-datareader.svg)](https://pypi.python.org/pypi/pandas-datareader/)

[![Codecov](https://codecov.io/gh/pydata/pandas-datareader/branch/master/graph/badge.svg)](https://codecov.io/gh/pydata/pandas-datareader)

[![RTD](https://readthedocs.org/projects/pandas-datareader/badge/?version=latest)](https://pandas-datareader.readthedocs.io/en/latest/)

[![Code Style](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)

[![License](https://img.shields.io/pypi/l/pandas-datareader)](https://github.com/pydata/pandas-datareader/blob/main/LICENSE.md)



## Installation



Install using `pip`



``` shell

pip install pandas-datareader

```



## Usage



``` python

import pandas_datareader as pdr

pdr.get_data_fred('GS10')

```



The public API is focused on macroeconomic, policy, and factor-style data

sources such as FRED, Fama/French, Bank of Canada, World Bank, OECD,

Eurostat, and the new `pandas_datareader.macro` interface.



## Documentation



[Stable documentation](https://pydata.github.io/pandas-datareader/) is available on

[github.io](https://pydata.github.io/pandas-datareader/). A second copy of the stable

documentation is hosted on [read the docs](https://pandas-datareader.readthedocs.io/)

for more details.



[Development documentation](https://pydata.github.io/pandas-datareader/devel/) is available

for the latest changes in master.



### Requirements



Using pandas datareader requires the following packages:



-   pandas>=1.5.3

-   lxml

-   requests>=2.19.0

-   distutils (not included in standard library of Python 3.12 and above it, which can be solved by installing `setuptools`)



Building the documentation additionally requires:



-   matplotlib

-   ipython

-   requests_cache

-   sphinx

-   pydata_sphinx_theme



Development and testing additionally requires:



-   black

-   coverage

-   codecov

-   coveralls

-   flake8

-   pytest

-   pytest-cov

-   wrapt



### Install latest development version



``` shell

python -m pip install git+https://github.com/pydata/pandas-datareader.git

```



or



``` shell

git clone https://github.com/pydata/pandas-datareader.git

cd pandas-datareader

python -m pip install -e .

```



↑