【问题标题】:Python/Pandas - long strings trimmed during import of Shapefile to GeoDataFramePython/Pandas - 在将 Shapefile 导入到 GeoDataFrame 期间修剪的长字符串
【发布时间】:2019-11-20 18:41:01
【问题描述】:

我观察到,在将 Shapefile 格式导入 Pandas DataFrame(使用 geopandas 包)期间,具有长值(超过 256 个字符)的列被修剪:

import geopandas as gpd
import pandas as pd

shp_file = gpd.read_file(observations.shp)

有没有办法绕过这个限制?

【问题讨论】:

    标签: python pandas shapefile geopandas


    【解决方案1】:

    这不是导入到 GeoDataFrame 的错。 Shapefile 最大字段宽度为 254。这是 dBase 格式的限制。

    【讨论】:

      猜你喜欢
      • 2017-12-14
      • 1970-01-01
      • 2016-03-19
      • 2012-01-19
      • 2021-12-22
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多